« first day (2271 days earlier)      last day (2590 days later) » 
00:00 - 16:0016:00 - 00:00

4:02 PM
@ErikE nice!
> You'll wish you had used a single database:
- When you discover a bug that affects all 1000 clients and deploying the fix to 1000 databases is hard.
> You'll be relieved you used multiple databases:
- When you discover a bug after deployment to a single customer db and you realize that the rest 999 are happily unware
 
4:20 PM
@MDCCL Thanks!
 
4:34 PM
@ypercubeᵀᴹ Everyone has a test environment. Some people are lucky enough to have a completely separate environment to pre-test in before they do the real testing.
I don't remember the quote exactly. I think I heard it here first.
 
Everybody has a testing environment. Some people are lucky enough enough to have a totally separate environment to run production in.
2
That is usually attributed as the source of the quote
Or were you thinking of something else @ErikE
 
@ErikE "I don't always test but when I do, I do it in production"? ;)
 
@jcolebrand Yes, I didn't say it exactly right.
I was thinking of it as, prod is always a test environment, but the saying is closer to "the first environment you run in is considered test"
 
Phil quoted it here some time ago. It was it much later that August 21, 2015, but perhaps it was quoted here around that time too.
Found it at last:
Nov 4 '16 at 17:43, by Philᵀᴹ
"Everyone has a test environment. Some people are lucky enough to have a separate environment to run production in as well."
 
5:05 PM
2 messages moved to Trash
 
5:41 PM
 
6:02 PM
@AndriyM yeah but mine predates that by over a year :p
 
@jcolebrand Yes, even as I'd admitted that in a preceding message (albeit in slightly broken English) :P
 
How's everyone's Friday?
 
I think they've finally left me alone. But I'll have to change this oh so important report tomorrow.
How's yours @jcolebrand?
 
Ehhhh, I'm tired, mildly cranky, and I don't write Java, I write C# (guess what i'm doing now ...)
 
Writing Java?
 
6:11 PM
sigh
yes
 
Never had the pleasure.
Hopefully never will
 
be glad it's not JavaScript
but, yes, Java is practically equally terrible.
 
Shhh, don't you talk bad about the perfect language
 
lol
 
We can bemoan java all day long, but ecmascript is perfection
 
6:14 PM
sure, if you like untyped variables.
 
Also, I finally learned where they got all the "awesome" syntax for TypeScript, and now I'm like 17 layers of annoyed
@MaxVernon I do.
 
that explains that, then
 
Duck typing is so much better when you honestly learn it and adopt it, and don't just bitch about it (which is what most people I hear bemoaning ecma are frustrated about, they never bothered to learn it)
Then again, I cut my teeth on C, and I know how nice dynamic objects can be
Most people only ever learned to work in a very tightly controlled JIT RT
 
true. I guess I like it tight.
 
Everything is just a pointer man
If it ain't a pointer, it's data
Need to add something else? Add a new pointer to your base object to point to the new data.
also, functions as first class citizens
 
6:19 PM
I love pointers, I also love being insulated from pointers-to-pointers.
I agree though, I do see the functional beauty.
 
@jcolebrand I just took my son to the dentist to treat a big infection and abscess above his front teeth, complications of an accident 2 years ago where one of his front teeth was knocked completely out of his head because the people at the house we were visiting forgot to tell him the rules of the playground slide that "everyone knew". And miss work to do it, when there are critical projects in flight that I need to make serious progress on.
 
Yeah...
 
@jcolebrand Yes, functions as first class objects. Awesomeness.
And I have to take him a couple of more times. And my wife can't do it because she's still recovering from major surgery.
No one told my son that the middle slide of 3 was reserved for going up, not down, so when he slid down feet first but face down (so he couldn't see ahead) and another child was climbing up, my son took out the other kid's feet and the kid landed directly on my son's head and smashed his face and tooth into the slide.
It is no consolation that they since then have torn out the slides completely.
So, not great Friday. Or week. Or month. Or perhaps even year, due to all the craziness happening lately.
 
6:44 PM
@MaxVernon pointers to functions (in C) are more fun.
 
6:57 PM
@Philᵀᴹ of course, if you really want to have fun, you just do it in assembler.
 
7:12 PM
I only know MIPS, 6502 and ARM
 
@MaxVernon it is still not clear to me, why does anyone need to know WeekOfYear depending on DATEFIRST? DATEPART(WEEK, AnyDate) should work according customer server settings
 
The week number varies depending on what day you consider the "first day of the week"
The OP in that question assumed it started on 7 always, I believe.
and now they've seen customers with it set to 1, and want to fix their data
I'm guessing.
 
I know, but does it matter if I run a query on my server or on your server?, the query should be the same. For example, if you need a report grouped by week , I wont write 7 different queries.
 
7:52 PM
@MaxVernon When I change the starting value to N'2017-12-31T00:00:00' in order to generate a series for 2018, the results show 0s in WeekOfYearStartingSunday.
(Not trying to be picky, I just happened to be interested by the problem)
 
@Forrest unfortunately, I don't have time to look at it right now. Will later on, though.
 
8:11 PM
@McNets if you save the results and send them to me, and our datefirst settings don't match, the week numbers won't line up properly.
 
8:50 PM
@MaxVernon O-Okay.
 
9:00 PM
@ypercubeᵀᴹ what's the aim of cast(name as bytea)?
 
@McNets it will show 'alice b' as \x616c6963652063 for example
20 is space. These must be some other characters that look like space
 
@ypercubeᵀᴹ ah ok, thanks
I'm trying with regex expressions, but I'm really bad with it
 
I don't think regexes are needed. You can check for spaces with LIKE.
Unless they want to search for any white space character.
Who knows. My best guess is they have done something wrong. If they reveal the whole query, we'll know.
 
I'm just training, I wont answer the question.
select id, name
from sometext
where name !~ E'[[:space:]]'
;
 
10:05 PM
@Lamak: I suggest ROWS UNBOUNDED PRECEDING for the running total (or rather: Aaron suggests)
 
@JackDouglas Can I suggest a new improvement on dbfiddle?
 
11:00 PM
Both technet.microsoft.com and msdn.microsoft.com are now redirecting to docs.microsoft.com for me. Curious.
 
Unless you choose technet.com, it does: docs.microsoft.com/en-us/sql/t-sql/functions/…
 
11:14 PM
0
A: Running Multiplication in T-SQL

ypercubeᵀᴹAnother method that uses the EXP(SUM(LOG())) trick and only window functions for the running total (no recursive CTEs or cursors). Tested at dbfiddle.uk: WITH ct AS ( SELECT ccp, years, quart, q2 = round(exp(coalesce( sum(log(sum(gts))) OVER (PARTITION B...

I hadn't answered at SO for a while.
How often does one get a chance to use 6 nested functions?
round(exp(coalesce(sum(log(sum(gts))) OVER (...) , 0)), 2)
 
Sometimes in SSMS I press F4 accidentally, which brings up the Properties window. How on earth do I close that pane with the keyboard? This window drives me mad.
 
@ErikE ;)
 
@ypercubeᵀᴹ Never mind that the sum of logs loses precision REALLY fast...
 
Ctrl + F4 or Shift + F4?
 
No, CTRL+F4 closes the currently open query window
Not the properties pane which has the focus
 
11:22 PM
@ErikE I don't expect it to be precise, if they want to multiply hundreds of values
 
I can press Ctrl + Tab to switch to the current query again, but how do I close the Properties pane?
@ypercubeᵀᴹ My impression is that it becomes pretty inaccurate after even just a few (4 or 5?) values
@ypercubeᵀᴹ But I would have to reassess to say for sure.
 
@ErikE that's why I rounded after applying the exp()
 
why does docs.microsoft.com look so terrible
 
@McNets Thanks!
 
11:35 PM
I'd suggest to set it auto-hide
 
@McNets Hmmmm then it still takes space
@McNets Though less
 
Just in case you press F4 again
 
The only thing useful I can see in the properties pane is server version
The others I can get when I need them or they're already displayed somewhere on the screen.
And the dropdown with 1 item in it is particularly amazing!!!
@McNets And yes I could have searched for that, and no I didn't, and yes I'm suitably ashamed.
 
@ErikE ;) it doesn't matter, I had same issue before, and it's the first time I looked for a solution
 
11:50 PM
Wait, does MySQL not support multiple values in a single INSERT statement, or does the OP simply not know that? stackoverflow.com/questions/43001133/…
 
I've deleted my answer there
He has changed 3 times his requirements
 
00:00 - 16:0016:00 - 00:00

« first day (2271 days earlier)      last day (2590 days later) »