Click here to monitor SSC
SQLServerCentral is supported by Red Gate Software Ltd.
 
Log in  ::  Register  ::  Not logged in
 
 
 
        
Home       Members    Calendar    Who's On


Add to briefcase 12»»

Aggregation in SQL Server 2008 Expand / Collapse
Author
Message
Posted Monday, September 14, 2009 3:04 PM
SSC-Enthusiastic

SSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-Enthusiastic

Group: General Forum Members
Last Login: Tuesday, October 15, 2013 5:16 AM
Points: 147, Visits: 104
Comments posted to this topic are about the item Aggregation in SQL Server 2008

Bhavesh
.NET and SQL Server Blog
Post #787769
Posted Monday, September 14, 2009 9:24 PM
Hall of Fame

Hall of FameHall of FameHall of FameHall of FameHall of FameHall of FameHall of FameHall of FameHall of Fame

Group: General Forum Members
Last Login: Thursday, July 17, 2014 10:56 AM
Points: 3,924, Visits: 1,607
How come Dec 3, 2009 question appeared on sep 14th?

SQL DBA.
Post #787871
Posted Tuesday, September 15, 2009 1:13 AM
SSCrazy

SSCrazySSCrazySSCrazySSCrazySSCrazySSCrazySSCrazySSCrazy

Group: General Forum Members
Last Login: Monday, July 21, 2014 2:56 AM
Points: 2,603, Visits: 2,061
I have parse the query in the query analyzer and got the following error:

Msg 102, Level 15, State 1, Line 3
Incorrect syntax near 'SETS'.


---------------------------------------------------
"Thare are only 10 types of people in the world:
Those who understand binary, and those who don't."
Post #787950
Posted Tuesday, September 15, 2009 2:20 AM


Hall of Fame

Hall of FameHall of FameHall of FameHall of FameHall of FameHall of FameHall of FameHall of FameHall of Fame

Group: General Forum Members
Last Login: Today @ 12:44 PM
Points: 3,907, Visits: 5,083
"Grouping Sets ()" is a new addition to T-SQL in 2008.
refer SQL2008 BOL page:
ms-help://MS.SQLCC.v10/MS.SQLSVR.v10.en/s10de_0evalplan/html/09f0096e-ab95-4be0-8c01-f98753255747.htm


____________________________________________
Space, the final frontier? not any more...
All limits henceforth are self-imposed.
“libera tute vulgaris ex”
Post #787975
Posted Tuesday, September 15, 2009 2:43 AM
SSC-Enthusiastic

SSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-Enthusiastic

Group: General Forum Members
Last Login: Tuesday, October 15, 2013 5:16 AM
Points: 147, Visits: 104
SanjayAttray (9/14/2009)
How come Dec 3, 2009 question appeared on sep 14th?


I am surprised too!


Bhavesh
.NET and SQL Server Blog
Post #787989
Posted Tuesday, September 15, 2009 2:01 PM


Mr or Mrs. 500

Mr or Mrs. 500Mr or Mrs. 500Mr or Mrs. 500Mr or Mrs. 500Mr or Mrs. 500Mr or Mrs. 500Mr or Mrs. 500Mr or Mrs. 500

Group: General Forum Members
Last Login: Monday, August 11, 2014 7:26 AM
Points: 540, Visits: 224
That's a question from the future! Are we sure on Dec 3rd the answer will be the same?
Kind of like those DOTS (Ice cream of the future!)

Post #788532
Posted Wednesday, December 2, 2009 10:03 PM
SSCommitted

SSCommittedSSCommittedSSCommittedSSCommittedSSCommittedSSCommittedSSCommittedSSCommitted

Group: General Forum Members
Last Login: Monday, August 18, 2014 8:25 AM
Points: 1,519, Visits: 2,550
Don't know how..when I opened QOD page today it shows that "My answer is correct" and I have been given 2 points. Infact I had not even seen the question...


Post #827929
Posted Thursday, December 3, 2009 5:23 AM


Hall of Fame

Hall of FameHall of FameHall of FameHall of FameHall of FameHall of FameHall of FameHall of FameHall of Fame

Group: General Forum Members
Last Login: Today @ 1:49 AM
Points: 3,033, Visits: 3,233
San-847017 (12/2/2009)
Don't know how..when I opened QOD page today it shows that "My answer is correct" and I have been given 2 points. In fact I had not even seen the question...


Lucky you! I got wrong when the page opened - not saying however if I would have got it right if I had seen the question though! - Well yes of course I would have done


-------------------------------
Posting Data Etiquette - Jeff Moden
Smart way to ask a question

There are naive questions, tedious questions, ill-phrased questions, questions put after inadequate self-criticism. But every question is a cry to understand (the world). There is no such thing as a dumb question. ― Carl Sagan
I would never join a club that would allow me as a member - Groucho Marx
Post #828068
Posted Thursday, December 3, 2009 7:22 AM
SSCrazy

SSCrazySSCrazySSCrazySSCrazySSCrazySSCrazySSCrazySSCrazy

Group: General Forum Members
Last Login: Yesterday @ 3:21 PM
Points: 2,501, Visits: 197
After moving the code to my SQL 2008 and rewriting it to work with an existing table I got some results. There were lines with the first field having a value and the second NULL. Then I got a set of lines with the first field NULL and the second with values. It was almost like running two statements, one grouping by the first field and the other grouping by the second field, then putting all the results together.

What was a bummer was that I didn't need to go to all the trouble as when I went to answer the question it automatically assigned the correct answer. Why can't it do that on those that I would get wrong?
Post #828143
Posted Thursday, December 3, 2009 8:18 AM


SSCrazy

SSCrazySSCrazySSCrazySSCrazySSCrazySSCrazySSCrazySSCrazy

Group: General Forum Members
Last Login: Today @ 3:12 PM
Points: 2,351, Visits: 2,696
Stuart Davies (12/3/2009)
San-847017 (12/2/2009)
Don't know how..when I opened QOD page today it shows that "My answer is correct" and I have been given 2 points. In fact I had not even seen the question...


Lucky you! I got wrong when the page opened - not saying however if I would have got it right if I had seen the question though! - Well yes of course I would have done


I lucked out too and got it right, though I can't recall whether I answered it back on 9/14. Pleasant surprise - and I'll take it, given the previous times when I thought I was "robbed" out of a point or two.

webrunner


-------------------
"Operator! Give me the number for 911!" - Homer Simpson

"A SQL query walks into a bar and sees two tables. He walks up to them and says 'Can I join you?'"
Ref.: http://tkyte.blogspot.com/2009/02/sql-joke.html
Post #828204
« Prev Topic | Next Topic »

Add to briefcase 12»»

Permissions Expand / Collapse