question

pits avatar image
pits asked

query for count

good day, After running query (select * from ROSS )I received 20 lacs rows,now those can not be exported to xl/csv....since xl has 10 lacs rows limitation.and even if I try to export it to xl/csv only 10 lacs rows getting saved Is there any command which give me records between 10lac and 20 lac row?to export remaining records? rgds,
querycountfor
10 |1200

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Leo avatar image
Leo answered
Try Select * from ROSS Where Row_ID
10 |1200

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Fatherjack avatar image
Fatherjack answered
Dont use select * in SSMS to export data. You would be much better off using SSIS to manage the extract and creation of the csv file. If you want a wizard to guide you through the steps then right click on your database and choose Tasks... Export Data. It will take you through the steps to export the data you want into a csv of your choice.
10 |1200

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

ThomasRushton avatar image
ThomasRushton answered
If you've not got a handy ID field, you could use a partitioning function. Something like: WITH RowNumberedCTE AS ( SELECT Field1, Field2, Field3, ROW_NUMBER() OVER (ORDER BY Field1) AS RowNumber FROM TableName ) SELECT Field1, Field2, Field3 FROM RowNumberedCTE WHERE RowNumber between 1 AND 10000 -- change this to get the next trenche of data ORDER BY RowNumber
10 |1200

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Scot Hauder avatar image
Scot Hauder answered
If you have excel 2010, install the power pivot extension from [here][1] Export your data to a text file then import to power pivot, it can handle millions of rows with highly efficient columnar compression. [1]: http://www.powerpivot.com/download.aspx
10 |1200

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Write an Answer

Hint: Notify or tag a user in this post by typing @username.

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.