« first day (2176 days earlier)      last day (2769 days later) » 
05:00 - 17:0017:00 - 23:00

ADH
5:00 PM
Filter repositories
 
ADH
It's not a personal repository
It's not a repository that belongs to an org I am a member of
So, yeah, I thought these things were public
 
@mikeTheLiar can you help me understand SQL Server backups a lil bit? I've quite a bit of reading, but I'm still slightly confused. You are semi familiar with them, right?
2 hours ago, by Michael
What is there difference between a Differential backup in SQL Server vs a Transaction log backup?
Like I understand that a differential is all the changes from the last Full backup, and a Transaction log backup is all the transactions from the last Full backup.

But why would you do a Full + Differential + Transaction? Why not just do Full + Diff OR Full + Transaction?
2 hours ago, by Michael
Okay reading more about the SQL Server backups it sounds like Transaction Log backups allow for Point-in-time recovery, where as differential does not.

So then it makes me curious as to why would you use Differential backups? Why not do something like Weekly Full + 15min Transaction Log backups? Is it because you'd have to include a TON of transaction log recoveries to get up until a certain point?
 
Well I'm not sure what differential backups are but transaction logs, as the name suggests, log transactions
 
5:04 PM
Hi,

Could we compare 2 arrays by simple say arr1 == arr2 ?
 
A transaction is a statement that is running but hasn't been commited yet
@Donovan you can compare memory address but not contents
@Michael so when you do something like this:
 
Hmm so how should I compare 2 1D arrays?
loop?
 
begin transaction
update SomeHugeTable
set SomeValue = SomeOtherThing
where someCondition
commit transaction
@Donovan yes
 
Is this valid code structure (or syntax sugar): <object>?.Method();
 
The transaction is stored in the log but not committed (finalized) until it's ready to be saved. That was if something goes wrong the transaction can be aborted and you don't end up with a database that's in the middle of an update statement
 
5:06 PM
for (int i = 0; i < 5; i++)
If (arr1[i] == arr2[i]?
 
@mikeTheLiar okay so anytime a CRUD occurs, a transaction is first created, and then later commited.
 
Right
 
ADH
Those GitHub tutorials are not what I need
 
But that transaction can be huge
 
ADH
THey are for your own repositories
 
5:07 PM
Think of the transaction log like this
When you open a word document and start editing it but don't save it, the changes that you made are stored in memory but not committed until you save them
That way you can cancel the changes at any point and not have to worry about whether or not your word doc is screwed up by the changes that you made
Doing some quick reading about differential back up, they're something completely different
That's just so you don't have to do an full backup every time
Transaction logs are ephemeral
They can go away at any time after they're not needed
 
ADH
I had to login to the website
 
One time I had a delete statement that was deleting something like a billion rows but the transaction log got too large to hold the entire transaction
So I had to do it in a loop and truncate the transaction log after every iteration
 
@mikeTheLiar okay, but lets say I do a simple insert command.. When it hit execute A transaction is created. and then I assume run immediately?
 
Run but there's still some time it takes to do the insert
 
and then the Transaction log just gets archived into some transaction log history.
 
5:11 PM
Right. Say you lose connection to the server right in the middle of issuing the insert statement
The insert can be safely abandonded by reverting the transaction
 
If the first i = the same as the i in the other array, the message is shown already, instead if the complete array is the same?
 
@Michael are you familiar with rollbacks?
@Donovan I have no idea what you're asking
 
i mean.. generally. rolling back to a previous state
 
@Michael I mean something like this:
begin transaction
-- do something dangerous here
rollback
 
Comparing 2 arrays.
But if I'm using a loop:

for (int i = 0; i < 5; i++)
{
if (try_letters[i] != mistery_word [i])
and else if (try_letters[i] == mistery_word[i])
then are the arrays always the same if i = 0
 
5:13 PM
@mikeTheLiar I assume the rollback command will rollback to before the transaction?
 
both arrays starting with the same value
 
Exactly
I use this a lot when I'm doing something that I want to make sure works before I just run it
 
@mikeTheLiar do you have to specify 'begin transaction'?
 
Last thing you want to do is run an update statement and see 10,000,000 rows affected because you forgot the where clause
@Michael so SQL knows where to rollback to
 
ah I see
 
5:15 PM
So how could I compare 2 arrays with an array but in a different way then what I do now.
 
update someTable set someValue = "something"
begin transaction
delete from someTable where someOtherValue = "something else"
rollback
The first statement will be committed. The second will be run, but not saved
 
Okay that makes sense. Thats actually super useful.
 
Indeed tis
 
But, so, you don't have much of experience with them in the context of backups?
 
Well they're not really relevant to backups, unless you're saving the transaction log in the backup
What was your question about full/differential backups?
 
5:18 PM
right, I'm trying to familiarize myself with backups. I read a lottt. And my question is about Full + Differential + Transaction Log backups.
 
@mikeTheLiar Didn't expect that :P
 
Well a full is exactly what it sounds like. The entire database is backed up
 
Apparently Transaction Log backups allow you to restore to a certain point in time
I understand full,
i understand diff
 
Ah I think I see. Transaction log backups save the state of the transaction log
 
but I dont really understand Transaction to much and why you wouldnt just use a combo go Full + transaction logs
 
5:21 PM
Well because restoring from a transaction log backup is something that hopefully won't have to go too far back
A couple of hours, a few days at most
 
Well the common practice seems to be something like this:
Weekly Full,
 
It's everything that's ever happened to the database
 
Daily / hourly Diff
15 min Transaction logs
 
That's some serious redundancy right there
Hope you've got a hell of a lot of storage
 
Idk... apparently we do.
 
5:22 PM
But yeah. The idea is that restoring from a transaction log backup is a very intensive thing to have to do
So this set up is:
 
but say I backup transaction logs every 15 mins.. why do we even need to do it every 15 mins? why not ever hour or day, or week if the log is going to be holding every transaction anyways?
 
Because that's a lot of information
This way you only have to store 1 hour worth of transactions
What I was going to say earlier:
1) did something go wrong in the last hour? Transaction log restore
2) in the past day? Backup
3) In the past week? Backup from the last good day
 
Whether its in 15 min increments or daily increments it still equals the same amount overall.
 
I bet they get thrown out when they're a couple hours old
 
hm maybe
 
5:25 PM
Think of it like this
You're reading a book and you lost your place
Do you want to have to start from the beginning to find where you were?
Or you just stick a bookmark in every 15 minutes
Take the bookmark that's furthest back and move it to your current position
 
Yes, but you still need all the previous 15 min backups in order. stemming from the last full backup
 
But that was an hour ago
Every time the diff is finished you have a full backup from that point
 
so you have to do Full + 15minA + 15minB + 15minC + 15 minD
right
 
Right
But you wouldn't want to do a diff every 15 minutes
Just like you wouldn't want to do a full every hour
 
right, I understand the full and differential part
I'll probably end up creating a test environment to play with
 
5:29 PM
I'm actually gonna go grab lunch
 
nothing better than practice
 
We can pick this up again later if you want
 
sounds good. Thanks!
 
cheer np :)
 
i need some help debugging, i am getting a Error executing child request for handler 'System.Web.UI.Page', and I cannot seem to find the problem through innerexceptions etc. is there a goto file in a .net project I can set a debug point, I HAVE to find a way to fix this. Or Event Viewer?
 
5:47 PM
Does anyone know the wordgame Lingo? I'm reproducing it, but I'm having a small problem.
 
Just ask your question
 
It's a word game where you need to guess a mystery word.
If you guess a letter correct somewhere, that letter is placed at the same position on the next line. But I don't know how.
 
Be more specific
 
Hmm okay let me think
 
@Donovan here we go again
 
5:51 PM
??
 
Okay the game field is 5x5. Each separated labels.
Each letter that is guessed correct (same letter as in the mystery word) then that letter should be placed at the exact same column index on the next row.
Even if you don't guess that letter in the next line, the same letter should come up a row later.
So if you guess a letter correct at 0, 1
at 1,1 and 2,1 and 3,1 and 4,1 should be the same letter
 
OK. What's the problem?
 
So what I was trying is:
current_line++;
                                for (int x = 0; x != 5; x++)
                                {
                                    if (correct_letters[x] != ".")
                                    {
                                        l[current_line+1, x].Text = correct_letters[x];
                                    }
So the next line, the correct guessed letter is at the same place, but a word later it's gone
so do I need to make a 2D array and save all the tries in that array?
Or how should I do that
 
However you like, we aren't going to write your code for you. Wouldn't it make more sense to find out what is clearing the cell text, though?
 
6:04 PM
No I know. I may have a solution.
 
is it possible to cast a Page to my PageBase class? PageBase ctrlPage = new Page(); .. i am trying to add controls to page and getting executing child request for handler 'System.Web.UI.Page'
 
You can't cast a child to a parent.
I feel like we discussed this recently.
 
@mikeTheLiar thank you
no not me, i learn good
 
lol not you specifically
The room
 
oh haha
and PageBase is abstract
so i cannot instantiate
i am in a .asmx.cs file can i get the parent PageBase()?
 
6:20 PM
is there any way to get the Namespace (parent) of the current User Control in c#?
 
...does that exist?
 
Yeah, I'm not sure that's a thing
You want to run a windows docker image on linux?
Or you want to run SQL Express on a linux docker image?
 
I've found the 2014 express windows image
and talk of SQL Server (full) on linux
But express, linux, docker, not in that combination
 
How could I implement in a 2D array a value a the same column in the entire array?
            string[,] letters = new string[,] {  {".", "A", ".", ".", "."} ,
                                                 {".", "A", ".", ".", "."} ,
                                                 {".", "A", ".", ".", "."} ,
                                                 {".", "A", ".", ".", "."} ,
                                                 {".", "A", ".", ".", "."} ,
                                                 {".", "A", ".", ".", "."} , };
 
user1881400
Howdy
 
user1881400
6:35 PM
I've got an interesting condition. I have a single thread with lots of events. I keep getting differences in behavior while running in release mode vs. debug mode from visual studio. This doesn't make sense since events are deterministic. I'm not doing floats and equality, so it's not that. Any ideas?
 
What gives you the impression that events are deterministic?
 
And what differences are you seeing?
 
@JoshuaLamusga You've given us nothing at all to work with
 
user1881400
@KendallFrey Well, I don't know what to give you. What are you looking for, exactly?
 
information
"My code doesn't work, why not?"
What happens if you run in debug mode without visual studio, or release mode with visual studio?
 
user1881400
6:41 PM
In debug mode, it works as expected. In release mode, it doesn't. Since I don't know much else, I can't tell you much else. If I could diagnose the specific error, I would've. But this is the third bizarre difference between debug and runtime behavior. This is a WPF app.
 
What is expected?
What is unexpected?
This is information that we need.
 
Try debugging it in release mode, maybe you'll find the problem
 
Try releasing in debug mode.
 
Try rebugging in delouse mode
 
user1881400
I wrote a syntax parser and interpreter for a text adventure engine. It's sort of complicated. It takes if-statements as nodes, where it stores nested ifs as children and evaluates them later. When an if condition is met, the innards are immediately parsed/interpreted using the engine. Sometimes, those conditions are timer or input-based, so I get data from a textbox. Continued...
 
user1881400
6:47 PM
...(since text adventures frequently use input) and subscribe the if condition to be re-evaluated at the end of that timer/textbox input event. So I've got a lot of asynchronous event firing, which is pretty much my problem. The thing is, it all looks right in the debugger, but doesn't fire the same in release mode. That is, certain things won't work and since it only happens in release mode (and only as a result of code optimization, by the way!) I can't debug it. Continued...
 
Please be more clear
is the problem the lack of a debugger, or release mode?
 
user1881400
...I don't know what to do because I can't find anything online to address events and debug vs. release behavior associated with them. So I can only find stuff talking about async patterns.
 
If your algorithm expects events from user input to be fired in a certain order, your algorithm is flawed
 
user1881400
The debugger can be attached with unoptimized code and it will work. The debugger can be detached with unoptimized code and it will work. Only when the code is optimized does it not work, or so I think I've discovered.
 
so try debugging in release mode
 
6:49 PM
You could write an adapter layer that buffers them to ensure they're only processed in a logical order, as long as you can cover all reasonable cases of what that order should be
 
and don't forget what they used before debuggers
Logging!
 
user1881400
When a user is entering input, there aren't any timers or other async things in the way. @KendallFrey I have lots of logging in here ;)
 
Well, does it give you any helpful information?
 
user1881400
I'm debugging in release mode, hold on
 
user1881400
Debugging with optimized code works. I thought it didn't work earlier, so maybe it's related to the debugger. Gah.
 
7:00 PM
i got it guys... boy that was a bear.. but well worth the learning
 
user1881400
Oh, never mind guys. I'll do some real thorough testing on this bug before coming back. I've got to go, though. Thanks for the help and suggestions Kendall Frey and Tom W. This is the 3rd bug like it and when I solved the last two, I thought they were a one-off deal. So I'll debug it thoroughly, hopefully get some meaningful results, and return with real questions.
 
user1881400
(I just realized I was doing these runs with my temporary workaround active)
 
7:21 PM
Hey
 
7:36 PM
I hate the shitty code the developers before me left me with... :(
Wasted a week prepping to simply change the naming of certain attributes, come to find out the names are hard-coded in numerous random SPs, Views, and functions. Not to mention these names are involved when authorization of a user to do various things.

Now that I know this it's too risky to try to guess and check through every little file everywhere and make sure these names aren't hardcoded somewhere
 
You're preaching to the choir
 
So now all the work i've done so far, i'll just undo
 
8:09 PM
@Michael Welcome to software development. Write 10,000 lines of code (or 10 KLOCS if you are l33t) and then only commit 50
 
And use very vague naming conventions
And then change halfway through
 
8:30 PM
the thing that gets me is they "made it a point" to think about how to implement things such that a future developers would understand... that didnt work out.
 
8:45 PM
Most solid truth in software development: The most permanent solution is a temporary solution.
 
828
A: What is the best comment in source code you have ever encountered?

Rohit// somedev1 - 6/7/02 Adding temporary tracking of Login screen // somedev2 - 5/22/07 Temporary my ass

 
9:03 PM
@RyanTernier if there wasn't time to fix it properly at the time you produced a temporary solution, what makes you think there will ever be as the Great Hourglass of the Universe runs down?
 
9:13 PM
@TomW Last night my fiance said "Ryan, can you please put calking behind the sink and ensure that all the windows are calked as I don't want to be cold this winter".
Me: Sure babe, I need to pick up some clear calking from the store because white would look aweful behind the sink.
Her: Please, oh pretty please do it in white. It's just a rental house, who cares.
Me: True, ok white it is, saves me a trip and I'll redo it when I get clear calking
Will it ever be clear? Probably not
 
9:55 PM
Hey guys, I have a database design question and I was hoping someone que enlighten me.
 
Well this isn't a database room, but what's your question?
They're super helpful (and friendly) in my experience
 
I can't seem to find a Database Room.
oh ok
a general room would be the best place to start, i suppose
thanks Mike
 
np
SQL question we can probably help with. Designed questions, maybe but who knows
 
10:17 PM
everyone is so quiet there
maybe i can pick your brain. Is not an SQL question, is more of a design matter as an overall.. (the big picture)
 
posted on September 30, 2016 by Scott Hanselman

It's official. I'm a better programmer when I'm pairing with someone. Pair Programming (two people, one keyboard) has been around for at least 20+ years, if not much longer. Usually one person types while another person (paces around and) thinks. It is kind of a "driver and navigator" model. Everyone is different, to be clear, so it's very possible that you are the kind of person who can d

 
10:58 PM
I have a question for all you wise programmers out there. I have a form that has tags, the client wants to have spaces, I have the front end mask all undersocres with spaces so when they appear it looks like there is spaces. But I want, for every two word tag entered, so substitute the space with an underscore, so I don't have any spaces in my tags cause spaces will mess everything up. What is the best tool to use for this?
 
05:00 - 17:0017:00 - 23:00

« first day (2176 days earlier)      last day (2769 days later) »