« first day (2279 days earlier)      last day (2586 days later) » 

12:19 AM
Please, don't let me answer nothing else tonight.
 
12:33 AM
I got a bowl of cereal and some trace flags
2
been a long week
 
Lately, all weeks been long weeks
 
 
3 hours later…
3:27 AM
@ypercubeᵀᴹ Yes that's exactly it.
 
 
6 hours later…
9:39 AM
@JackDouglas error report: dbfiddle.uk/…
Replace 95 with 96 and it shows this:
> Internal Server Error

22P02ERROR: invalid input syntax for type json
DETAIL: The input string ended unexpectedly.
CONTEXT: JSON data, line 1:
This is the query that breaks:
SELECT POWER(2.0, 96.0) ;
 
9:55 AM
I guess it's overflowing and the output / json conversion fails
 
10:08 AM
@PaulWhite did you try the April fish thing?
 
@TomV hm?
 
Apr 1 '16 at 7:39, by Paul White
I just told my wife. If we remember, next year we will attempt the paper poisson.
Somehow I remembered
 
Sadly I completely forgot! How sad.
sets a reminder for 1 April 2018
 
My godchild successfully put one on my back which reminded me
 
 
3 hours later…
1:36 PM
@ypercubeᵀᴹ Thanks, I fixed that — odd quirk of .NET: stackoverflow.com/questions/19231957/…
@JoeObbish Does this prove there is some type conversion involving float going on even for POWER even in 2016? dbfiddle.uk/…
 
2:05 PM
@JackDouglas I left you a comment. Also: the conversion semantics were changed for compatibility level 130.
I would illustrate using db<>fiddle but we're not allowed to change database compatibility level.
SELECT CONVERT(numeric(20), CONVERT(float, CONVERT(numeric(20), 18446744073709551616)));
But try that ^ under compat 120 & 130 on 2016.
Essentially, SQL Server used to round to max. 17 digits as part of conversion from float/real to numeric/decimal. Now it attempts to keep all available precision.
This is normally good, but there are edge cases that may be unexpected, like:
SELECT POWER(CONVERT(numeric(38,0), 10), 38);
Error under 120; 99999999999999997748809823456034029568 under 130.
A similar semantic change affecting conversions between datetime and datetime2 is mentioned in Breaking Changes to Database Engine Features in SQL Server 2016.
 
3:09 PM
I put that in an answer.
 
4:02 PM
@PaulWhite thanks, this is interesting :)
What is the 'if necessary in 'The first input is implicitly cast to float if necessary'?
 
@JackDouglas Well it's not necessary if the value is already a float :)
 
@PaulWhite ah, OK. I thought Martin was suggesting it doesn't always get cast when it isn't a float.
 
I think I'll stick with not using the POWER function
 
@JackDouglas In the answer, yes. He revised that in a comment. I incorporated all that in the improved answer.
 
@PaulWhite I'd need to grant ALTER DATABASE for that, which I don't think would be safe, right?
 
4:07 PM
@JackDouglas Probably not!
 
-1 for comments, and -1 for me for not reading them :(
 
DECLARE @d1 datetime = '2000-01-01 00:00:00.997';
DECLARE @d2 datetime = '2000-01-01 00:00:01.000';
SELECT DATEDIFF(MILLISECOND, @d1, @d2);
Returns 3 under 120, 4 under 130.
 
Hah, we round all times to the nearest second!
I am still secure in my bubble
 
Ha well that's OK then :)
 
@PaulWhite That doesn't make sense.
I mean, it does in light of what you said earlier, but...
 
4:15 PM
@AndriyM Yes it does. You just don't understand it ;)
 
Apparently
 
DATEDIFF counts the number of boundaries crossed.
 
Bounty up for grabs
10
Q: Empty blocking process in blocked process report

Tom VI'm collecting blocked process reports using Extended Events, and for some reason in some reports the blocking-process node is empty. This is the full xml: <blocked-process-report monitorLoop="383674"> <blocked-process> <process id="processa7bd5b868" taskpriority="0" logused="106108620" waitr...

 
datetime accuracy is 1/300s = 0.00333333...
 
Oh, so it's because it's .99666666... really, I see
 
4:18 PM
@AndriyM Yes exactly. It crosses 4 boundaries.
 
Is "DIMENSIONFOCUSUNPROCESSEDTRANSACTIONS" a table name?
 
CREATE TABLE DIMENSIONFOCUSUNPROCESSEDTRANSACTIONS (x int) <-- yes.
 
what kind of a terrible person would do such a thing?
 
@PaulWhite <-- him
 
Someone who types in all caps a lot?
 
4:20 PM
An Ancient Greek fan?
 
don't ancient Greeks have lower case table names?
 
well I will offer an upvote and my sympathy
 
@JackDouglas ha! touché!
 
@JoeObbish yes but the table name is irrelevant
I see it often on different queries
 
Oh! It's a table in Tom's question!
 
4:22 PM
 
Sure but that's what I got out of the question (pretty much know nothing about deadlocks)
 
No.
ALLCAPITALWITHOUTSPACESBETWEENWORDS
NOITCERIDGNIGNAHCDNUORASPARWTAHT
 
awesome
 
how is that possible to read?
couldn't it be ambiguous?
 
Greek grammer helps
you couldn't parse English like that
 
4:25 PM
"grammer" LOL
 
just think
you could have corrected the error
instead you laugh!
 
@ypercubeᵀᴹ warps or wraps?
 
poor Jack
 
On mobile but the table name is irrelevant it happens all over
 
@JoeObbish I even clicked edit on the message before deciding not to fix it but point and laugh instead.
I am a terrible person.
 
4:26 PM
@JackDouglas That's my bad. Is it "wraps around"?
 
@ypercubeᵀᴹ do't worry your English is 100% better than my koine
or is that older?
 
I wo't ;)
 
do'''t
 
500 rep offered cause I really want an answer
 
@JackDouglas I think that is from 5th century BC
 
4:32 PM
that is ancient
 
Paul, do you happen to know of a good resource for how to run a debugger against SQL Server other than the articles by Klaus Aschenbrenner?
 
@JoeObbish No I really don't.
 
Hmm, ok. I suspect that it's beyond my abilities then
 
@JackDouglas You can see the K's and E's that change direction from line to line in the picture
 
what's the logic in that?
less eye movement as you read?
 
4:35 PM
start the new line exactly below the last word of the previous line? Not sure
It wasn't used always as far as I know.
 
A crossed letter is a manuscript letter which contains two separate sets of writing, one written over the other at right-angles. This was done during the early days of the postal system in the 19th century to save on expensive postage charges, as well as to save paper. The technique is also called cross-hatching. This is distinct from a palimpsest as manuscripts were written this way at one sitting or for the same purpose (such as a diary), rather than being re-used later. == References == == External links == Media related to Crossed letters at Wikimedia Commons...
also bonkers
 
ha, nice. I hadn't seen that before!
Boustrophedon /ˌbuːstrəˈfiːdən/ (Ancient Greek: βουστροφηδόν, boustrophēdón “ox-turning” from βοῦς, bous, “ox”, στροφή, strophē, “turn” and the adverbial suffix -δόν, "like, in the manner of"; that is, turning like oxen in ploughing) is a kind of bi-directional text, mostly seen in ancient manuscripts and other inscriptions. Every other line of writing is flipped or reversed, with reversed letters. Rather than going left-to-right as in modern European languages, or right-to-left as in Arabic and Hebrew, alternate lines in boustrophedon must be read in opposite directions. Also, the individu...
from Bous (ox) and strophe (turn)
Like you use your ox to plough.
 
Hello.
 
Ha. And wikipedia uses the word "boustrophedonically". Sounds rificulous
 
boustropheyllacinod
 
4:42 PM
@JackDouglas page compression!
2
 
@ypercubeᵀᴹ It probably does. I'll be more certain when I know what that word means.
 
5:02 PM
IF OBJECT_ID('tempdb..#SearchItems') IS NOT NULL DROP TABLE #SearchItems;
Does .. mean there isn't any schema on tempdb?
 
It certainly has the dbo schema, because I know I can create tables like dbo.MyTable in tempdb, and I never created the schema myself.
 
@McNets you can use .. anywhere
 
I'm having a look at @MaxVernon answer here: dba.stackexchange.com/a/168806/110455
 
@McNets Schema is ignored for #temporary tables. Try it with tempdb.GalacticPenguin.#SearchItems for example.
 
@PaulWhite @JoeObbish @AndriyM ok, thanks
@JoeObbish is there any implicit schema then?
 
5:09 PM
Each user has a default schema.
 
@McNets the behavior I've observed is that SQL Server will try your default schema and fall back on dbo
but that might not be exactly correct
 
I think that's right. My understanding is that an .. omitted schema behaves exactly as name resolution does when just the unqualified table name is specified.
 
That sounds reasonable.
 
The rules for name resolution are complex though, and have changed over the years.
Specifying an explicit schema is the best thing to do.
I'd never noticed before that the question author's comments get a special highlight around the user name.
 
5:27 PM
@PaulWhite me neither — maybe it's new?
 
Jeff Atwood on August 23, 2009

In order to increase engagement between the people asking questions and the rest of the community, we’ve rolled out two new features.

The first is a “batting average”, if you will.

Below the question owner signature block, for non-community-wiki questions, we show the percent of accepted answers for that user. It won’t always appear, though. The following rules are used in the calculation:

Questions must not be community wiki.

Questions must not be community wiki.

Questions must not be closed. …

> Another change we made is to highlight comment responses from the user who asked the question.
August 2009! Can't believe I had never noticed that.
@JackDouglas And if you delete a comment from the question author, your name gets highlighted too!
 
5:43 PM
once had an issue where two tables in a dev database had the same name and almost had identical data
I think one of them had an extra row
 
@JoeObbish there is an Oracle table that has almost identical data with itself
 
6:02 PM
@PaulWhite Does that mean I 'should' delete all my unaccepted answers? At least those that the OP has never accepted another one, nor commented anything else?
 
@McNets No because that's an old post and accept rate isn't a thing any more.
 
@PaulWhite AH ok.
 
In the Suggested Edits review queue, when you look at the details of the review process, the post's author's name is also highlighted when they accept or reject the suggestion.
 
@McNets I believe that accept rate used to be for questions that you asked
so if you asked 10 questions and marked 9 of them with an accepted answer you'd have 90%
a meta post I read once suggested that it was removed because users were harassed if they had a low score
"why should I answer your question when you have a 0% accept rate?"
 
6:14 PM
@JoeObbish the same on the opposite side: "why should I accept the answer of someone with 20% of accepted answers"
 
@McNets You shouldn't have read that comic!
 
@JackDouglas is this a system table?
 
@ypercubeᵀᴹ haha
 
@JoeObbish yes, DUAL
 
@JackDouglas I know the table but don't know what you mean. Is there something cute that you can do with it?
 
6:18 PM
8
A: How does the Oracle DUAL table work?

GaryIncidentally, DUAL is one of the few 'tables' that works when the instance has been started but the database hasn't been opened. You get something like ADDR INDX INST_ID D -------- ------ ------- - 0C0362D4 0 1 X

fun stuff
 
didn't know about dual2
I like the one and only answer from "I know more than you"
 
@JoeObbish dual2 is created by the OP
"…when I create my own dual table?"
 
oh, that's why I didn't know about it
can't agree with the "never use it in production" quote in the top answer...
 
"It shouldn't be used in production, unless you specifically need to invoke certain procedures through SQL" Why not? — Nick Pierpoint Aug 22 '11 at 16:20
I use it in production all the time and I think most people do
especially with SELECT rownum FROM DUAL CONNECT BY LEVEL<=100 etc
 
6:53 PM
@AndriyM Ooo
 
7:19 PM
@McNets see this for some more details about schemas in tempdb.
 
@MaxVernon thanks
 
My pleasure
 

« first day (2279 days earlier)      last day (2586 days later) »