RE: [PHP-WIN] SQL to select a set of records

From: Date: Fri, 06 Feb 2004 16:00:37 +0000
Subject: RE: [PHP-WIN] SQL to select a set of records
Groups: php.windows 
Request: Send a blank email to php-windows+get-22750@lists.php.net to get a copy of this message
No. What I said was correct, as Ron wanted rows 25-35. -----Original Message----- From: Stuart [mailto:lists@sharedserver.net] Sent: 06 February 2004 12:45 To: David Felton Cc: Nadim Attari; php-windows@lists.php.net; Herhuth, Ron Subject: Re: [PHP-WIN] SQL to select a set of records David Felton wrote: > SELECT TOP 10 dbo.Table_MIS_Files.File_ID > FROM dbo.Table_MIS_Files > WHERE dbo.Table_MIS_Files.File_ID NOT IN > (SELECT TOP 25 dbo.Table_MIS_Files.File_ID > FROM dbo.Table_MIS_Files) Shouldn't this be... SELECT TOP 25 dbo.Table_MIS_Files.File_ID FROM dbo.Table_MIS_Files WHERE dbo.Table_MIS_Files.File_ID NOT IN (SELECT TOP 10 dbo.Table_MIS_Files.File_ID FROM dbo.Table_MIS_Files) That will get rows 11-25. -- Stuart ********************************************************************** This email and any files transmitted with it are confidential and intended solely for the use of the individual or entity to whom they are addressed. If you have received this email in error please notify the system manager. This footnote also confirms that this email message has been swept by MIMEsweeper for the presence of computer viruses. **********************************************************************

« previous php.windows (#22750) next »