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 123»»»

How many partitions? Expand / Collapse
Author
Message
Posted Wednesday, August 11, 2010 10:29 PM


SSCarpal Tunnel

SSCarpal TunnelSSCarpal TunnelSSCarpal TunnelSSCarpal TunnelSSCarpal TunnelSSCarpal TunnelSSCarpal TunnelSSCarpal TunnelSSCarpal Tunnel

Group: General Forum Members
Last Login: Today @ 5:30 AM
Points: 4,121, Visits: 5,488
Comments posted to this topic are about the item How many partitions?

____________________________________________
Space, the final frontier? not any more...
All limits henceforth are self-imposed.
“libera tute vulgaris ex”
Post #967927
Posted Wednesday, August 11, 2010 10:34 PM


SSCommitted

SSCommittedSSCommittedSSCommittedSSCommittedSSCommittedSSCommittedSSCommittedSSCommitted

Group: General Forum Members
Last Login: Tuesday, November 25, 2014 11:09 PM
Points: 1,940, Visits: 1,173
Hi ,

I guessed correctly as 4.but i executed the script it is throwing error in the last statement.because group by is not there in the last statement.

Is it working for sqls server 2005 or 2008?

after throung error i put group by and executed it is showing zero rows.

unfortunately i put answer as zero but anser is correct.


Malleswarareddy
I.T.Analyst
MCITP(70-451)
Post #967928
Posted Wednesday, August 11, 2010 11:15 PM


SSCarpal Tunnel

SSCarpal TunnelSSCarpal TunnelSSCarpal TunnelSSCarpal TunnelSSCarpal TunnelSSCarpal TunnelSSCarpal TunnelSSCarpal TunnelSSCarpal Tunnel

Group: General Forum Members
Last Login: Today @ 5:30 AM
Points: 4,121, Visits: 5,488
malleswarareddy_m (8/11/2010)
Is it working for sqls server 2005 or 2008?

Logical partitioning of tables was introduced with SQL Server 2005.



____________________________________________
Space, the final frontier? not any more...
All limits henceforth are self-imposed.
“libera tute vulgaris ex”
Post #967936
Posted Thursday, August 12, 2010 1:02 AM


SSCertifiable

SSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiable

Group: General Forum Members
Last Login: Yesterday @ 5:21 AM
Points: 6,098, Visits: 8,367
malleswarareddy_m (8/11/2010)I guessed correctly as 4.but i executed the script it is throwing error in the last statement.because group by is not there in the last statement.

Based on visual inspection of the code, you appear to be right about the missing GROUP BY. I'm glad I overlooked that when answering! Luckily, there is no generic "error" answer option, so people will hopefully realise that this is an unintended mistake.

after throung error i put group by and executed it is showing zero rows.

Did you load the table with data? Millions of rows is not necessary, but at least one in every partition is.



Hugo Kornelis, SQL Server MVP
Visit my SQL Server blog: http://sqlblog.com/blogs/hugo_kornelis
Post #967957
Posted Thursday, August 12, 2010 1:02 AM


Ten Centuries

Ten CenturiesTen CenturiesTen CenturiesTen CenturiesTen CenturiesTen CenturiesTen CenturiesTen Centuries

Group: General Forum Members
Last Login: Yesterday @ 5:23 AM
Points: 1,409, Visits: 1,316
The query without group by looks strange.
In case the table is populated, it must return millions of rows.




See, understand, learn, try, use efficient
© Dr.Plch
Post #967959
Posted Thursday, August 12, 2010 2:01 AM
UDP Broadcaster

UDP BroadcasterUDP BroadcasterUDP BroadcasterUDP BroadcasterUDP BroadcasterUDP BroadcasterUDP BroadcasterUDP Broadcaster

Group: General Forum Members
Last Login: Monday, June 9, 2014 9:48 AM
Points: 1,493, Visits: 207
Question is tricky. At a glance, it seems to have syntax error as there in no GROUP BY clause.
But, if we ignore it then
Post #967979
Posted Thursday, August 12, 2010 2:45 AM
SSCommitted

SSCommittedSSCommittedSSCommittedSSCommittedSSCommittedSSCommittedSSCommittedSSCommitted

Group: General Forum Members
Last Login: Today @ 5:55 AM
Points: 1,813, Visits: 6,586
Hugo Kornelis (8/12/2010)
Based on visual inspection of the code, you appear to be right about the missing GROUP BY. I'm glad I overlooked that when answering! Luckily, there is no generic "error" answer option, so people will hopefully realise that this is an unintended mistake.


I spotted the missing group by, so assumed that since none of the non-error options could possibly be right, it must be the first option, and that the error was being raised before it got as far as the 'no group by' error.
Post #967996
Posted Thursday, August 12, 2010 3:28 AM


SSCertifiable

SSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiable

Group: General Forum Members
Last Login: Yesterday @ 5:21 AM
Points: 6,098, Visits: 8,367
Frankly, I never understand why people do take the considerate effort to assemble and submit a question, along with an explanation and some believable answer options, and then don't take that tiny bet of extra effort to ensure no unintended syntax errors by copying and pasting their code in SSMS and hitting the execute button. That should not take more than a minute, tops!


Hugo Kornelis, SQL Server MVP
Visit my SQL Server blog: http://sqlblog.com/blogs/hugo_kornelis
Post #968026
Posted Thursday, August 12, 2010 7:13 AM
Ten Centuries

Ten CenturiesTen CenturiesTen CenturiesTen CenturiesTen CenturiesTen CenturiesTen CenturiesTen Centuries

Group: General Forum Members
Last Login: Thursday, January 31, 2013 8:01 AM
Points: 1,228, Visits: 1,046
I selected error becuase with the given code example it was the answer closest to the result. I understand the point your question was trying to make. Your question failed to provide the right answer not me. Please corrrect this.
Post #968152
Posted Thursday, August 12, 2010 7:31 AM
SSC Eights!

SSC Eights!SSC Eights!SSC Eights!SSC Eights!SSC Eights!SSC Eights!SSC Eights!SSC Eights!

Group: General Forum Members
Last Login: 2 days ago @ 8:00 AM
Points: 985, Visits: 1,839
OK, so it wasn't just me staring and trying to decide between "error" and "4" then. Finally picked "4" because that error wouldn't be the GROUP BY error.
Post #968171
« Prev Topic | Next Topic »

Add to briefcase 123»»»

Permissions Expand / Collapse