« first day (1555 days earlier)      last day (3611 days later) » 
01:00 - 20:0020:00 - 23:00

JNK
JNK
01:59
@KrisGruttemeyer sorry I missed this, got sucked into something
yeah material was good, a lot of it was sort of remedial for me but a lot of it was very helpful
this was a DEV conference not a DBA one
 
1 hour later…
03:01
Wooo, Yearling badge! Time to find a spanner and take the training wheels off. (I read that Google has one; maybe I could borrow it?)
03:34
helloo
 
2 hours later…
05:41
@ypercube Don't worry, someone else did:
A more sinister wording of this question is "How can I get you to resign if I don't like you as a mod?" — ryanyuyu 8 hours ago
 
2 hours later…
07:59
@Zane There are some people I work with who get really excited about his techniques for manipulating row goals and forcing parallelism and forget to look at basic things like normalization, indexing, and simplifying queries first.
 
2 hours later…
09:50
Posted a question for the Mods elections: meta.stackoverflow.com/questions/289449/…
Any resemblance to so users, mods or not, regulars in the heap or not, is entirely on purpose ;)
+1d
@MaxVernon not a very clear question
@Lamak it remains a mystery, I'm afraid
 
2 hours later…
11:48
@ypercube sheepishly leaves
@bluefeet Your question is the highest voted - among those with no downvotes.
It's amazing how almost everything in meta gets some downvotes.
@ypercube both of my questions have been very visible things that have happened on SO in the past several months which is probably why they've been accepted.
Your question is really good, just makes me feel a bit bad if it seemed that I overstepped when I became a mod.
I don't think you overstepped anything.
Morning everyone
"Irrelevant. You have no friends."
12:04
> got pissed off by some comments. I hate giving complete solutions but here you go:
@ypercube "Please don't be vulgar"
haha
I suggested to the same guy yesterday - in another question - to add something in his answer. His response:
> I like giving mysterious answers.
@KrisGruttemeyer i hadn't noticed that!
@ypercube Haha, I thought that was the best part
It got my attention in the question list. Aaron editing a mysql question? This must be something.
@ypercube funny, this is a draft that I wrote before leaving work yesterday:
> Let's assume that before being elected a mod you used to frequent a SE chatroom. Users there are very knowledgeable (sometimes), but some have a tendency to post some snarky comments (which points to real problems with the question/answer)......

Disclaimer: I'm assuming that the candidates are gonna answer truthfully
12:19
@Lamak haha
we have different disclaimers ;)
@ypercube yeah, mine was to avoid certain comment from a certain user
user tool
@Lamak :(
@bluefeet but it's a good thing I didn't finish it, because we got a better worded one
If my q gets selected, my vote will go to whoever answers "Surprised. I am the one with the most snarky comments." ;)
And I would just love to see Kermit's answer, if he pursued with the nomination.
12:30
It's all good. I'm totally comfortable with my actions. Just giving you both a hard time
The blue feet can't hide anything
@bluefeet that's because your actions were the right ones
13:29
I love seeing indexes like Col1,Col2,Col3 INCLUDE Col4 and then another index That's just Col1, Col2, Col3, Col4 with no includes
what's wrong with that?
:P
:D
When i said redundancy, that is not what I meant
@KrisGruttemeyer it's better when you realize that the table only columns are col1, col2, col3 and col4
@Lamak That would be all kinds of win
13:42
Time to truge through the old index design and optimization book. I want my key column to address the JOIN columns first, right? Then the WHERE columns, then includes for anything returning that isn't being used to filter/join?
@KrisGruttemeyer Does it not depend if they are INNER or OUTER joins?
Equality operators first, then inequality
@MarkSinkinson I would think that it would. It's an INNER.
this guy had this doubt for many many years....
0
Q: Why do I have to sometimes specify the database.tablename?

ElijahThis is something that has bugged me for many many years and have never asked. Why is it that when writing SQL against a schema in a databases, whether it be Oracle, Postgres, MySQL or MSSQL I have to specify the database name and the table name? e.g. SELECT id FROM mydb.mytable; and other times...

@MarkSinkinson Should I consider the selectivity of the equality operators first?
And index the most selective as the first key column?
I think...
13:52
@MarkSinkinson That would make sense as it can narrow down as much as possible first
@KrisGruttemeyer That's the general idea
It's half technical knowledge and half art designing some of these
I swear I read/heard that exact comment the other day...
@KrisGruttemeyer sometimes it's the WHERE columns first, then the ones used in JOIN
Only one way to find out, test
So loving this
I like the Phone one
@swasheck Yes! I saw that yesterday and lol'd
@mmarie iirc, you have more time for memes.
@PaulWhite yeah.
14:54
Right now i do. My client can't be bothered to build the tables i need. So I'm doing some QA and then reviewing Summit abstracts and working on my presentation for Friday.
Present Spray. Not an airhorn. LOL
@swasheck Also, that was not a "you are late to the party" statement, that was meant to say "this is funny and everyone should watch it". Emphasis was on the lol, not the yesterday.
@mmarie no worries. i didnt really care if it was a "you are late to the party" statement because ... well ... i've spent the last week pulling cognos' head out of its own ass
haha
are you done for now?
depends.
14:57
Cognos's head is out of it's ass so now it must wear Depends to prevent it from defecating the DW?
somehow it leaked that a dev created an index in production and that has been touted as the root cause because that changed all of the query plans from then until the end of eternity.
@PaulWhite ... and i'm still an idiot ... a slow learner who'd need your intelligent guidance on the histogram comparison thing. if you ever wanted to do a blog post with pretty pictures on how the histos are aligned for joins then that'd be awesome because i still dont understand which values it'd use to set as boundary points. yes. i'm an idiot.
@swasheck It also got your dog pregnant. Please spay or neuter your pets
@mmarie ... my money is on the fact that the selectivity of one of our dimensions is blowing up query plans
@swasheck I so wish I could just star individual parts of this
@swasheck I don't really know what you mean by selectivity
15:01
@billinkc let me help
"i'm an idiot"
@swasheck Here, have some angry owls mediumlarge.wordpress.com/2015/04/02/outraged-owls
4
@swasheck now, remove the quotes and it will get starred faster ;.)
+1, would star again
@mmarie that's excellent
@Lamak pobrecita. past the editing window
@swasheck That doesn't make sense and it's the wrong gender.
15:04
@mmarie that's part of the fun. it doesnt make sense
I don't know, @Lamak might secretly be a girl.
and swash is an idiot
your logic has no jurisdiction here in my brain
@billinkc that's no secret
this sentence no verb
Bow didi bow di dang di dang diddy
15:05
@swasheck 1. Draw two small histograms next to each other. 2. Where a boundary touches a non-boundary, extend it so it splits the non-aligned boundary in two. 3. Do the obvious math. 4. Profit.
Lost me at histogram
2
@MikeFal I am not
sooooo ...
no. that was wrong.
It's national empanada day in the US, in case anyone needs lunch ideas.
7 mins ago, by swasheck
"i'm an idiot"
15:10
@mmarie didn't know you had empanadas over there
@Lamak We have everything. Except you
And your secret femininity
Thought that was implied
@Lamak Of course we do! We have empanadas and arepas and hallacas and tamales.
15:16
hallaback
and chimichangas
and taquitos
and crunch wraps
and chalupas
and sesame chicken
@MikeFal you're doing it wrong
aaaaand now I'm hungry...
@mmarie On purpose, no less
15:20
Forest Gump should include a thin line from one ocean to the other.
@mmarie nice
My Side of the Mountain? dafaq is that? It's not even a movie, it's a book.
Minneapolis should have been circled with Jingle all the Way technically.
/Shudder
@ypercube "Sam, a brilliant child, leaves home for the mountains after being told that the family summer trip has been canceled, thus preventing him from doing the algae experiments he had planned for that summer."
That's some hard hitting drama right there
15:32
OH: not only is that number completely irrelevant it's totally wrong.
I love coming to the Eagain office.
I like how 8 Mile and The Rock get little itty-bitty circles
Any reason why running this query on system should take long, trying to pull memory usage by database? mssqltips.com/sqlservertip/2393/…
Been running for almost 10 minutes now, VM with 8GB RAM.
Never mind, think I figured it out
@ShawnMelton And? What did you find?
It can be contention on the underlying system structures exposed by the DMV. Not much you can do about latching but this is a case where I would typically use a WITH (READUNCOMMITTED) hint.
15:47
The counter value Aaron used in his filter does not exist, so the CASE was churning on calculating, the "@total_buffer" was NULL: db_buffer_percent = CONVERT(DECIMAL(6,3),
db_buffer_pages * 100.0 / @total_buffer)
My todo from the our standup: Why did something not get somewhere?
Totally not vague, right?
Since "Total Pages" does not exist, could he be meaning Buffer Node:Database Pages or Buffer Manager:Database Pages?
I doubt thats the cause of the slow performance, though it still needs fixing of course.
Did anyone ping @AaronBertrand yet?
was fixing to
ping Aaron that is
@billinkc Because you put it in that place where you put that thing that time
16:00
According to that link, the new counter is Total Server Memory (KB) under LIKE '%Memory Manager', which would need converting to pages as well.
Not sure that is 100% counting the same thing though.
Given the other changes in what goes where memory-wise.
I might be tempted by: src.db_buffer_pages * 100.0 / SUM(src.db_buffer_pages) OVER ()
It does not seem to be something anyone has written much about with 2012
Ah, just found this shows that Total Pages translates to "Total Node Memory (KB)" in 2012.
@ShawnMelton That's the same link I posted above. And you're reading the table wrong. That's for SQLServer:Buffer Node, scroll up a bit to see Total Pages for SQLServer:Buffer Manager. I would still use the SUM OVER instead.
Ah, my bad
It's a confusing area.
WITH src AS
(
   SELECT
       database_id,
       db_buffer_pages = COUNT_BIG(*)
    FROM sys.dm_os_buffer_descriptors WITH (READUNCOMMITTED)
    --WHERE database_id BETWEEN 5 AND 32766
    GROUP BY database_id
)
SELECT
   [db_name] =
        CASE [database_id]
            WHEN 32767 THEN N'Resource DB'
            ELSE DB_NAME([database_id])
        END,
   src.db_buffer_pages,
   db_buffer_MB = src.db_buffer_pages / 128,
   db_buffer_percent = CONVERT(DECIMAL(6,3),
       src.db_buffer_pages * 100.0 /
16:24
^saving that one
16:35
@PaulWhite That worked, took about 7 minutes on client server. Thanks!
@KrisGruttemeyer It's all Aaron's work, I just added a hint and the SUM bit.
Only for the past 5 days
With a brief interruption to non-service on Sunday and Monday before they realized there were bad things going on
@PaulWhite are you running for Stack Overflow moderator?
ha ha ha ha ha
good
geez, you guys it's not that bad
17:00
Funny part of the story...finding the database memory usage I send an email to the client and they immediately come back asking if I am on the right server. I stated it had only 8GB, they said that server has 32GB....screenshot I sent says otherwise though :)
@ShawnMelton Well THERE'S your problem :D
Then they responded with this server is configured to "vendor recommendations"...hmm
@bluefeet I don't want to be an anything moderator.
@ShawnMelton what's the sp_configure for max server memory ... also, what's the OS version and edition?
Max is set to 6GB, Window Server 2012 Standard (I think is the right edition). I'm not on the server anymore.
17:13
@Zane I wanna be an airborne ranger!!!
@ShawnMelton hmph. ok
[This]( dba.stackexchange.com/questions/97306/…) is something I d love to know, but is it on-topic for DBA.SE?
@swasheck That's what I wanted to do out of High School
@MichaelGreen you have to get past the 50% chance that you can actually login and that live.com isn't wetting its diapers
@Zane ah. i wanted to be a hotshot
@swasheck I thought that said you wanted to be hotshit
@bluefeet just one
too many ghost peppers
OH: "i don't want anyone to be fired ... i'm just saying that we want you to understand that when we say that devs shouldn't have sa access in production environments we're not just saying it to be dickheads."
17:27
@MichaelGreen I'd love to know if that's possible, too. I think it's fringe as far as 'on-topic' but it's definitely something that seems to have interest.
Unfortunately for me I deal with 2005, 2008R2 and 2014
at least you have 2014
Going there this year. Going with AGs. After we do that I have to start upgrading the last few 2005 boxes.
@AaronBertrand are you available? I need to debunk something and I know I've heard to talk many times about situations where without and ORDER BY there is not guarantee of order.
@Zane Without an ORDER BY there is no guarantee of order.
2
A coworker is arguing that if he does ORDER BY when inserting into a table it will always come out that way. I'm trying to explain that that is indeed not the case.
There we go. Thank you sir.
Coworker is wrong. What he is seeing is coincidental and not guaranteed at all. He's already spent more time arguing about it than he would have spent typing out the damned ORDER BY clause.
I don't know why people want to argue about shit that happens to work right in a certain scenario when they can guarantee it in all scenarios with a few keystrokes.
Feel free to screen shot this chat and give it to your co-worker. I'll gladly prove him wrong directly.
I'm about to get on a plane, so maybe not immediately.
@Shawn Yeah those were written before 2012 came out, I don't know why I used Total Pages there. That would be based on the underlying OS, though, not version of SQL Server.
@AaronBertrand That's exactly what I said.
So why is he arguing? To be an asshole?
This is an ongoing saga of me being right and him being stupid.
17:47
because he's an idiot who believes that a relation is a lifo buffer
Or fifo. Idiots disagree.
@Zane Tell him The Heap says "hi"....and "you're stupid, stop arguing"
The only guarantee is when the table has <=1 row.
Same dude is running into dupes and wants to just throw on an Identity column instead of my suggestion of investigating where they are coming from.
@Zane aaah, so he's also inept
17:53
Same guy as yesterday.
Our "DataWarehouse DBA"
@KrisGruttemeyer For me it would have to know to switch between MSDN and Technet.
@Zane jeez, and he can't be bothered to look into the reasons for duplicate rows?
@Zane Yeah, because IDENTITY columns make your data unique.
"Which John Smith at 123 Appleseed Drive is this?" "Oh it's the one with ID = 16217
I like to join to a baby name book
That way each row gets a name to make it unique.
@AaronBertrand he and i go waaaaaaay back
@ypercube i always get the idiot type confused. i guess that makes me another idiot
18:02
jebus, I hate people that answer a question that's trivial and that has already been answered on a comment
-1
Q: Order by Consecutive Numbers in SQL Select

clamchodaI was wondering if there is a way to order by consecutive numbers in Sql Server 2008. Currently I have "Select StoreNum, StoreName, Date, Time From tbl_stores ORDER BY StoreNum, Date" Which will give me 1 | Toronto Store    | 2015-03-04 | ... | 1 | Toronto Store    | 2015-03-05 | ... | 2 | ...

I really want the power to unilaterally close question for 30k users
@PaulWhite ... this is a tremendously helpful blog post in helping us troubleshoot performance issues on our server
I'm working from home the rest of the day. I'm done wasting my time and energy on this.
hey @billinkc since you complain a few days ago about it, I've requested feedback on getting rid of it - meta.stackoverflow.com/questions/289708/…
feel free to answer/comment
@swasheck Partitioned tables have been a great source of blog material.
Aaand he's going with the identity column
Eff this noise. Thank god I'm off for the week.
"If I have a Primary Key it's going to take to long to load." shoot me!
18:22
> The problem only occurs with partitioned tables with a GROUP BY or DISTINCT over three or more columns using an aligned partitioned index, where a single partition is processed.
this is the salient point for our situation
@Zane that's ridiculous. Are you sure that guy know what a Data Warehouse is?
@swasheck That's the thing about weird edge cases. They keep coming up in reality :)
Many people wouldn't know enough to recognise there was a problem. So give yourself a gold star.
i wouldnt have noticed it without your post ... sooo ... silver star
18:37
Good afternoon @all
Anyone have time for a quick TSQL sys tables question?
23 hours ago, by Lamak
is it interesting and well written?
@Lamak I can make it so ;)
@Lamak Ask me interesting questions and I'll give you interesting answers
@KrisGruttemeyer ask me stupid questions and I'll just slap you
2
I'm just looking at the SEDE sys tables here trying to find if there is a table with composite keys. I just don't really understand all this back-end stuff, I normally mostly deal with front-end DDL
18:45
@bluefeet You may actually knock some sense into me. My wife will appreciate that. :)
I want a table like that for benchmarking a few different ways to write a specific type of front-end query.
@sᴉɔuɐɹɥԀ just use is_primary_key = 1, group by the table and see if it has more than 1 row
Ah ok, perfect thank you!
@Lamak You could even slap a window function in there and just isolate the ones with more than one column.
Unless that's what you were suggesting in the first place
in which case, carry on
@KrisGruttemeyer That's what I would use, but it was simpler to explain the logic behind it I guess
18:51
@Lamak I thought that's where you were going with it but I thought about going through a large result set looking for times when the table name appeared twice and my eyes started to hurt bleed. Figured I'd toss in my .02. :)
19:01
Hm, strange. is_primary_key is false for all indexes there. Odd.
anyone want to write this book?
0
Q: What is the difference between DBMS & RDBMS?

SyrionAs per this blog , the key difference between DBMS & RDBMS states: Key Difference between DBMS and RDBMS So what is the main difference between DBMS and RDBMS? The key difference is that RDBMS (relational database management system) applications store data in a tabular form, while DBMS...

@sᴉɔuɐɹɥԀ why?, maybe they are using heaps on the info that they share with us
Lost me there lol. I'm definitely more of a DB grunt than a DBA :)
I mean that they could be using tables without a primary key
Ah gotcha.
19:12
Sounds like a heap of trouble, to me.
@sᴉɔuɐɹɥԀ You could have a clustered unique index that isn't a PK
Please for making this go away plzkthxbainao:
-1
Q: What's is the difference between ROW and LOG type_desc

diegoxfsWhat's the difference between rows and log type_desc in sys.master_files ?

@sᴉɔuɐɹɥԀ Just out of interest, what is it exactly you're looking for? All indexes with more than one key? Just unique compound indexes? Just unique compound primary keys (clustered or nonclustered)? Also: why? Genuinely interested; not being confrontational.
@MikeFal this really deserves more love (though you're implying that a PK is necessarily a CI)
19:21
@swasheck You and your specifics can suck it.
you suck it
@Lamak Repro's for me.
@swasheck #twhs
@Lamak If you are removing things using the GUI, you're doing it wrong.
CLI ALL THE THINGS
19:23
@MikeFal What's the PowerShell for renaming an object? The T-SQL syntax is horrible.
@MikeFal I'm not, just saw this question
0
Q: Is it normal for the Delete key not to work when trying to rename a DB/table?

Michael GoldshteynI try to rename a database or a table in SSMS 2014 (with CU6 applied), by clicking and selecting the DB or table in the Object Explorer and then pressing F2 to edit the name. The Delete key on my keyboard will not delete the character to the right of the cursor. Is this just a problem on my end ...

@PaulWhite weird, I have no problem at all
ouch
> A real developer could fix this problem in a few minutes. For Microsoft, 4 years and it's still broken. Microsoft needs a new SQL Server Manageability team leader to help get everyday simple issues like this resolved, issues that thousands have to get annoyed with daily.
Yes, let the butthurt flow
@PaulWhite Invoke-SqlCmd -Query "exec sp_rename 'foo','bar'
@Lamak Right-click a database name, select "rename", hit [delete] key (not backspace). Nothing happens for me. SSMS 2014, Windows 7 x64.
@PaulWhite Repro'd here too. SSMS2014.
DELETE Y U NO WORK
@PaulWhite yeah, no problem whatsoever
@MikeFal No improvement then. sys.sp_rename is horrible and counter-intutive, especially IIRC for renaming indexes or columns. Prefixing issues.
though I have my keyboard on spanish
@Lamak What version of SSMS?
19:27
@KrisGruttemeyer I'm glad that I could make some people miserable on a 5 years old bug that you didn't know
@PaulWhite Yeah, kind of my point. :) Powershell is great, but offers no real advantage to T-SQL in this case.
@Lamak Interesting. It's a minor frustration with an easy workaround (I'd probably hit backspace first anyway).
@Lamak I didn't know it was a bug, I just decided it wasn't worth the effort to look into. I just kept using backspace :D
@MikeFal OK. Couldn't be sure.
@PaulWhite Though I still abhor doing things through the SSMS GUI and avoid it if I can.
19:28
@Lamak I hate that issue
@MikeFal there's not a SQLPS:> .......\mv old_object new_object?
@PaulWhite yeah, still weird that they decided not to fix it
@KrisGruttemeyer just deleted a prod table name. thanks obama
4
@swasheck I don't believe so. And in many cases using the provider is worse then calling T-SQL.
@MikeFal Yes. That's the only reason that delete bug stuck in my mind - it's one of the few things I do use the GUI for.
19:30
@KrisGruttemeyer SSMS 2012
@PaulWhite See this:
SELECT
  AVG(Cont.Equipment_Retail)
FROM STAR_Contracts AS Cont
  INNER JOIN STAR_Products AS Prod
    ON Cont.Contract_Number = Prod.Contract_Number
    AND COUNT(Prod.Contract_Number) = 1
WHERE Prod.Product_ID = '1018'
  AND Prod.Sequence_Number = '001'
GROUP BY Cont.Equipment_Retail;
I kind of got over it and relinquished myself to just using backspace, now that we've been talking about it, it's bugging me more (excuse the pun)
lexmark, i think i see your problem
I was curious to see where I could put the COUNT(Prod.Contract_Number) = 1 condition to get best performance
i.e., in the Join, in the Where or at the end with Having
does that actually even parse?
19:32
@sᴉɔuɐɹɥԀ is that working?
@Lamak great minds
AFAIK, I don't have direct access to the DB (writing for someone else). I was going to "translate" it to use SEDE so I could test for optimization
oh, I know that one....think alike?
@Lamak exactly.
:-)
19:33
@sᴉɔuɐɹɥԀ SEDE?
@swasheck Parsed for me
Doesn't mean it will actually run
@KrisGruttemeyer compile? my point is ... that doesnt look like valid syntax
@sᴉɔuɐɹɥԀ How do you want to optimize a query using completely different tables?
@swasheck Stack Exchange Data Explorer
@swasheck Not sure, but the parser thinks it's legit. We've seen issues where SSMS thinks it will run but the albegrizer doo-doos itself.
So parse != compile
@Lamak ONE QUERY TO RULE THEM ALL. ONE QUERY TO FIND THEM. ONE QUERY TO BRING THEM ALL AND IN THE DARKNESS BIND THEM
@KrisGruttemeyer a fair point and a good thing to note.
19:37
@swasheck In keeping with the LOTR theme, the algebrizer says 'YOU SHALL NOT PASS'
@Lamak Good question. I'm afraid the only honest answer is: I don't know :)
@KrisGruttemeyer @swasheck Yes, you thought you were getting a good plan, then the parameter sniffing led you into the SQL Server equivalent of Moria.
"What's the elvish word for 'timeout, good enough plan found'?"
I was going to test all 3 ways and check the execution plan to see how the engine treats each version.
> An aggregate cannot appear in an ON clause unless it is in a subquery contained in a HAVING clause or select list, and the column being aggregated is an outer reference.
@MikeFal Mellon
19:40
select i.name, count(p.index_id)
from sys.indexes i
	join sys.partitions p
		on i.object_id = p.object_id
		and i.index_id = p.index_id
		and count(p.partition_number) = 1
group by i.name
@sᴉɔuɐɹɥԀ but the tables, datatypes, indexes, data inside them are all different, what would be the point?
@MikeFal fly, you fools
@swasheck Ah you're right, I didn't even think of that
@MikeFal those are mutually exclusive, arent they?
@sᴉɔuɐɹɥԀ it's valid MySQL syntax, i'm sure ... but MySQL isnt a valid RDBMS
4
19:42
Msg 1015, Level 15, State 1, Line 18
An aggregate cannot appear in an ON clause unless it is in a subquery contained in a HAVING clause or select list, and the column being aggregated is an outer reference.
@PaulWhite suuuuure. one-up me with the error number, level, and state ... and a better formatting.
@PaulWhite Yet again, SSMS = "Sure thing", Algebrizer = "NOPE"
wait, was that for swashecks query above?
or Phrancis?
@KrisGruttemeyer believe so ... my query was to demonstrate the error that i believed would occur
@swasheck Oh sorry I thought you were just writing a compound-index-finding query, didn't notice the aggregate in the on clause.
in The 2nd Monitor, Oct 22 '14 at 21:48, by Phrancis
@Mat'sMug is not anything a bad idea on MySQL? ;-)
19:45
@PaulWhite i was just trying to figure a quick way to repro the syntax structure that @sᴉɔuɐɹɥԀ was proposing
@KrisGruttemeyer One of my own. Same error for @swasheck's example.
@swasheck Yes I understand now, I just didn't before.
@PaulWhite sometimes i feel like you just dont get me
i mean. are you even listening anymore?
Who said that.
some nobody
I wasn't listening actually - but only because I was writing an AdventureWorks query in SSMS using a COUNT in the ON clause.
19:49
Probably shedding some tears of nostalgia for pubs all the while
And while disgusting, the photo in this tweet has caused much laughter twitter.com/Iykke_Ii/status/585142424835649536
@billinkc aaaaaand we're done with the chicken noodle soup. forever.
@sᴉɔuɐɹɥԀ The problem with that is the optimizer will produce a reasonable plan based on the indexes and data distribution of the SEDE data set. Chances are, the same SQL syntax with your table names substituted will generate a completely different execution plan, because the optimizer's search path and cost estimates will all be different.
@PaulWhite oh, oh, I tried to say the same:
13 mins ago, by Lamak
@sᴉɔuɐɹɥԀ but the tables, datatypes, indexes, data inside them are all different, what would be the point?
@sᴉɔuɐɹɥԀ Rewriting a query using different syntax (while keeping the semantics exactly the same) is a valid tuning technique, but it's close to last resort. Write the query naturally, against a well-indexed relational database, with representative metadata e.g. statistics - chances are high the optimizer will find a good plan. Until you have that baseline, you have no basis for analysis or rewriting the query (as a last resort) anyway.
Also, your backwards name makes pinging you manually a bit awkward.
@PaulWhite You'll be seeing upside down for a few minutes, just sit back and enjoy. Most people have to pay for stuff like that
19:56
@sᴉɔuɐɹɥԀ In summary, I think you're doing things backwards. Could be fun and educational, but that's the main value you're going to get out of the SEDE exercise. Be careful not to learn stuff that's wrong, though :)
@Lamak Yes I know. I wanted to say it too, using different words.
do you understand the words that are coming out from my mouth?
@PaulWhite you mean, better words. And with more authority
@Lamak No, I meant different :)
@swasheck Who are you asking?
@PaulWhite @Lamak Thanks for entertaining my beginner DBA questions :)
Thanks for asking entertaining questions :)
19:59
@PaulWhite just quoting bad movie lines
I don't write SQL that often, and when I do it's mostly in Access (yuck) or Postgres
@swasheck You know I get precisely zero movie / meme references.
@PaulWhite that's why it's funny
that's why i respect you so much, @PaulWhite
01:00 - 20:0020:00 - 23:00

« first day (1555 days earlier)      last day (3611 days later) »