Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
Discussion Groups
Database Servers
DB2InformixIngresMS SQLOraclePervasive.SQLPostgreSQLProgressSybase
Desktop Databases
FileMakerFoxProMS AccessParadox
General
General DB TopicsDatabase Theory
Related Topics
Java Development.NET DevelopmentVB DevelopmentMore Topics ...

Database Forum / DB2 Topics / April 2006

Tip: Looking for answers? Try searching our database.

FETCH FIRST ROW ONLY

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
nymano - 07 Apr 2006 15:22 GMT
Hi.

Just a brief question: Are "FETCH FIRST ROW ONLY" and "FETCH FIRST x
ROWS ONLY" DB2 specific or SQL92?

thanks for any help,
nymano.
Knut Stolze - 07 Apr 2006 17:03 GMT
> Hi.
>
> Just a brief question: Are "FETCH FIRST ROW ONLY" and "FETCH FIRST x
> ROWS ONLY" DB2 specific or SQL92?

Definitively not SQL92.  And I could find it neither in SQL:2003 or SQL:200x
(which will be the next version of the standard, hopefully in 2007).

Btw, nobody cares about the SQL92 standard any longer.  SQL:2003 is the
current one.

Signature

Knut Stolze
DB2 Information Integration Development
IBM Germany

Serge Rielau - 07 Apr 2006 23:33 GMT
>> Hi.
>>
>> Just a brief question: Are "FETCH FIRST ROW ONLY" and "FETCH FIRST x
>> ROWS ONLY" DB2 specific or SQL92?
Submissions for the next round of the standards are on and IBM is moving
to standardize a clause. Politics typically dictate that no vendor's
existing syntax ever gets through unchanged, but syntax is easily
modified. :-)
My money is on something like mySQL's OFFSET x LIMIT y.

Cheers
Serge

Signature

Serge Rielau
DB2 Solutions Development
IBM Toronto Lab

Troels Arvin - 18 Apr 2006 21:26 GMT
> Just a brief question: Are "FETCH FIRST ROW ONLY" and "FETCH FIRST x
> ROWS ONLY" DB2 specific or SQL92?

"FETCH FIRST ..." is DB2's proprietary way to limit result sets.

DB2 offers SQL:2003's way, also. In fact now that MS has released MSSQL
2005, it seems that all of the "Big 3" support SQL:2003's "window
function" approach, see http://troels.arvin.dk/db/rdbms/#select-limit

Signature

Greetings from Troels Arvin, Copenhagen, Denmark

 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2009 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.