Thursday, January 3, 2008

Sybase Annoyances

One of the things that I really hated about Sybase is its lack of support for the use of the top keyword in subquries, for example:

SELECT
    field1,
    (SELECT TOP 1 field1 FROM table2 WHERE id = table1.id) myfield
FROM
    table1

This works in SQL Server but not in Sybase.

This is as of Sybase ASE 12.5, I don't know if this changed in Sybase ASE 15, so, if you have any idea about it please share this with us in the comments section.

No comments:

Post a Comment