SQL Clone
SQLServerCentral is supported by Redgate
 
Log in  ::  Register  ::  Not logged in
 
 
 

Get your favorite SSC scripts directly in SSMS with the free SQL Scripts addin. Search for scripts directly from SSMS, and instantly access any saved scripts in your SSC briefcase from the favorites tab.
Download now (direct download link)

Generic paged data like MySQL LIMIT

By dion,

This works, however code is creating a live temp_1 table in the database instead of using a #temp_1 temporary table because is just would not work.

The next idea I had was to use a unique table name per connection for temp_1, but I would really rather use temporary tables.

I am hoping some SQL guru's can suggest some improvements to this script.

Total article views: 116 | Views in the last 30 days: 1
 
Related Articles
FORUM

sql syntax issue

Hi, I am getting error in my below sql statement Declare @sqlquery varchar(max) Set @sqlquer...

FORUM

Perform a count and then another count

Hi, I have multiple users per account ie Acc A User1 User2 User3 Acc B User4 User5 User6...

FORUM

How to Tune Queries

Hi All Following attachment is a sql plan of a query that i have to tune query is insert ...

FORUM

CREATING A 2ND TEMP TABLE BASED ON THE CONTENTS OF 1ST TEMP TABLE`

#temp_1 returns 50,000 with probably 3000 unique part numbers. Now i need to make another temp tabl...

FORUM

Stored Procedure for paged data like MySQL LIMIT

The following code is intended to provide a server side solution for outputing data in pages given a...

Tags
miscellaneous    
t-sql    
 
Contribute