Click here to Skip to main content
15,891,033 members
Home / Discussions / Database
   

Database

 
AnswerRe: Get databases Pin
John-ph2-Sep-07 20:43
John-ph2-Sep-07 20:43 
AnswerRe: Get databases Pin
shivvish2-Sep-07 21:12
shivvish2-Sep-07 21:12 
GeneralRe: Get databases Pin
Syed Mujtaba Hassan2-Sep-07 22:42
Syed Mujtaba Hassan2-Sep-07 22:42 
Questionlogin problem in sql server express Pin
prasadbuddhika2-Sep-07 17:50
prasadbuddhika2-Sep-07 17:50 
AnswerRe: login problem in sql server express Pin
M LN Rao2-Sep-07 21:32
M LN Rao2-Sep-07 21:32 
AnswerRe: login problem in sql server express Pin
John Gathogo3-Sep-07 20:28
John Gathogo3-Sep-07 20:28 
QuestionSQL Order By in paging algorithim Pin
Polymorpher2-Sep-07 11:50
Polymorpher2-Sep-07 11:50 
AnswerRe: SQL Order By in paging algorithim Pin
Colin Angus Mackay2-Sep-07 12:04
Colin Angus Mackay2-Sep-07 12:04 
Umm... Wow!

There are a number of things that are wrong with this before we even get to solving the problem you posted about.

1. Why are you creating a stored procedure like this?

2. Your code is vulnerable to a SQL Injection attack.

3. The use of SET ROWCOUNT should be discouraged because it will affect other queries that happen to be running at the same time. Use SELECT TOP n instead (where n is the number of rows you want)

If you are running SQL Server 2005 the answer is quite simple as there is some new functionality built in to address this problem. If you are running SQL Server 2000 then it is workable, but the query will be more complex. Which version of SQL Server are you using?


Upcoming FREE developer events:
* Glasgow: Agile in the Enterprise Vs. ISVs, db4o: An Embeddable Database Engine for Object-Oriented Environments, Mock Objects, SQL Server CLR Integration, Reporting Services ...

My website

GeneralRe: SQL Order By in paging algorithim Pin
Polymorpher2-Sep-07 15:50
Polymorpher2-Sep-07 15:50 
GeneralRe: SQL Order By in paging algorithim Pin
Colin Angus Mackay2-Sep-07 22:54
Colin Angus Mackay2-Sep-07 22:54 
AnswerRe: SQL Order By in paging algorithim Pin
Colin Angus Mackay2-Sep-07 14:06
Colin Angus Mackay2-Sep-07 14:06 
GeneralRe: SQL Order By in paging algorithim Pin
Polymorpher2-Sep-07 15:51
Polymorpher2-Sep-07 15:51 
GeneralRe: SQL Order By in paging algorithim Pin
Colin Angus Mackay2-Sep-07 22:56
Colin Angus Mackay2-Sep-07 22:56 
Questioncount query Pin
Deian2-Sep-07 7:12
Deian2-Sep-07 7:12 
AnswerRe: count query Pin
Arjan Einbu2-Sep-07 11:18
Arjan Einbu2-Sep-07 11:18 
GeneralRe: count query Pin
Deian2-Sep-07 20:57
Deian2-Sep-07 20:57 
GeneralRe: count query Pin
Arjan Einbu2-Sep-07 21:29
Arjan Einbu2-Sep-07 21:29 
Questionwhat is the difference between roles Pin
prasadbuddhika1-Sep-07 16:45
prasadbuddhika1-Sep-07 16:45 
AnswerRe: what is the difference between roles Pin
Vasudevan Deepak Kumar2-Sep-07 0:51
Vasudevan Deepak Kumar2-Sep-07 0:51 
QuestionSQL 2005 Execute permissions Pin
mtone1-Sep-07 5:57
mtone1-Sep-07 5:57 
Questionerror!! Pin
Rharzkie1-Sep-07 1:44
Rharzkie1-Sep-07 1:44 
AnswerRe: error!! Pin
Vasudevan Deepak Kumar2-Sep-07 0:50
Vasudevan Deepak Kumar2-Sep-07 0:50 
AnswerRe: error!! Pin
Paul Conrad2-Sep-07 5:32
professionalPaul Conrad2-Sep-07 5:32 
Questioni can't connect in the connection wizard! Pin
Rharzkie1-Sep-07 0:45
Rharzkie1-Sep-07 0:45 
AnswerRe: i can't connect in the connection wizard! Pin
Vasudevan Deepak Kumar1-Sep-07 1:20
Vasudevan Deepak Kumar1-Sep-07 1:20 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.