Sybase and SQL Server

  • I know that SQL Server and Sybase were basically the same thing way back before SQL 6.5, but how closely related are they now?

  • They still have a lot of commands like DBCC and others that work the same, but the overall query engine is different and 7 was a complete buildup from scratch. As for syntax differences there are quite a few but the only way to know what is to find an online Sybase manual and compare.

  • A good history can be found in Kalen Delaney's Inside SQL Server 7 or Inside SQL Server 2000. It covers the difference.

    Both use T-SQL, so the commandsets are very similar, as Antares has pointed out.Also, the protocol SQL Server and Sybase both use to communicate with clients is the same: Tabular Data Stream (TDS). Microsoft and Sybase both have their extensions to TDS, but at the foundational level they both use the same protocol.

    K. Brian Kelley

    http://www.truthsolutions.com/

    Author: Start to Finish Guide to SQL Server Performance Monitoring

    http://www.netimpress.com/shop/product.asp?ProductID=NI-SQL1

    K. Brian Kelley
    @kbriankelley

  • Just a few comments...I just recently switched from Sybase to SQL Server and here are a few of the differences that I've noticed. Some of these may be supported in Sybase, but I didn't use them at that time:

    -IGNORE_DUP_ROW on index creation (not in SQL Server)

    -SELECT TOP (not in Sybase??)

    -sp_showplan (not in SQL Server)

    -SET PARALLEL_DEGREE (not in SQL Server)

    I'm sure there are many others, but these are a few.

    -Dan


    -Dan

  • IGNORE_DUP_ROW on index creation (not in SQL Server)

    It was but removed. From BOL

    quote:


    No longer supported. Using either ALLOW_DUP_ROW or IGNORE_DUP_ROW in the CREATE INDEX statement generates a warning message. If there is no unique clustered index and there is a need to avoid duplicate rows, create a unique constraint on one or more columns other than the clustering key


    -SELECT TOP (not in Sybase??)

    I am pretty sure there but may depend on version.

    -sp_showplan (not in SQL Server)

    Replaced by SET SHOWPLAN_TEXT ON or any of the others.

    -SET PARALLEL_DEGREE (not in SQL Server)

    I believe it was removed from the individual query and instead is max degree of parallelism option under sp_config.

    I'm sure there are many others, but these are a few.

    Edited by - antares686 on 12/01/2002 8:52:13 PM

  • SELECT TOP is new as of SQL Server 7.0. It doesn't exist in SQL Server 6.5. You have to use SET ROWCOUNT prior to the query. Testable by setting a database back to 6.5 compatibility level. Found this out when I was trying to figure out the database structure for a vendor's network monitoring software. It set the DB at 6.5 compatibility level and I issued a SELECT TOP 10 from a particular table and get the error msg.

    K. Brian Kelley

    http://www.truthsolutions.com/

    Author: Start to Finish Guide to SQL Server Performance Monitoring

    http://www.netimpress.com/shop/product.asp?ProductID=NI-SQL1

    K. Brian Kelley
    @kbriankelley

  • The way in which triggers are implemented seem to be different too. In Sybase speak you refrence old values as 'old', new as 'new', whereas in SQL Server you get at them through the views 'inserted' and 'deleted'. Although 7 was a ground up rebuild from 6.5 (and hence Sybase), I can't help but notice that both engines have uncannily similar issues (sysdepends issues for example)

  • Just like Windows XP has its roots in Windows 95. Products have a way of digressing. Consider that SYBASE and Microsoft haven't collaborated for 10+ years on a data base. You're going to find common ground because both have ANSI SQL support but the tools and management thingeys are going to be vastly different.

Viewing 8 posts - 1 through 7 (of 7 total)

You must be logged in to reply to this topic. Login to reply