in reply to which method is more faster?

unfortunatelly,The script report following Error:
Panic: dynamic SQL (? placeholders) are not supported by the server yo +u are connecting to at /usr/local/lib/perl5/site_perl/5 .8.8/i686-linux/DBD/Sybase.pm line 133.
I think the DB Server doesn't support Method 2.In this case,whether or not only Method 1 can be used ??

Replies are listed 'Best First'.
Re^2: which method is more faster?
by CountZero (Bishop) on Jul 25, 2007 at 06:33 UTC
    You are testing against a Sybase server (or using a Sybase-driver), whereas the original post is stating you are using MS SQL Server 2005, so at least your comments are confusing if not entirely misleading.

    MS SQL Server 2005 being the latest incarnation of Microsoft's database server series, it seems unlikely that it does not support '?' placeholders.

    CountZero

    A program should be light and agile, its subroutines connected like a string of pearls. The spirit and intent of the program should be retained throughout. There should be neither too little or too much, neither needless loops nor useless variables, neither lack of structure nor overwhelming rigidity." - The Tao of Programming, 4.1 - Geoffrey James

      Agreed, try DBD::ODBC instead.

      There are still other methods, such as ADO, but in my experience, ODBC works well. (And I can't wrap my head around ADO, but YMMV.)

      Actually it's FreeTDS's implementation of Sybase's Client Library API that doesn't support placeholders (yet!).

      Michael