PEPPLER.ORG
Michael Peppler
Sybase Consulting
Menu
Home
Sybase on Linux
Install Guide for Sybase on Linux
General Sybase Resources
General Perl Resources
Freeware
Sybperl
Sybase::Simple
DBD::Sybase
BCP Tool
Bug Tracker
Mailing List Archive
Downloads Directory
FAQs
Sybase on Linux FAQ
Sybperl FAQ
Personal
Michael Peppler's resume

sybperl-l Archive

Up    Prev    Next    

From: Michael Peppler <mpeppler at peppler dot org>
Subject: Re: ct_sql or ct_execute
Date: Nov 7 2001 12:44AM

"Cox, Mark" wrote:
> 
> Greetings!
> 
> I have been using the Ct_Lib for about a year and it has worked wonderfully.
> I haven't noticed any difference in efficency between using ct_sql  to run
> an update command or using ct_execute.      Is one way actually 'better'
> than the other for running an update command?

ct_sql() has the advantage of handling all the processing, so you don't have to
worry about handling various return codes, etc.

As usual, it's a question of control vs. ease of use. ct_execute() gives you
more control (because you have to code the ct_results loop, and so you can handle
error conditions with more care), but ct_sql() is easier to use and faster
(and will be just fine for almost all cases of running updates or inserts).

Michael