Re: How should environment be configured to use timex with isql?
Posted in 2006
Topics: Stored Procedures & SPL, Connectivity: ESQL/C, 4GL & Embedded SQL, Server Administration, Platform-Specific Issues, Versions, Editions & End-of-Life
Art S. Kagel wrote: > Dave Thacker wrote: > > Get Jonathan Leffler's sqlcmd package. It has a benchmark mode (enabled > with the -B commandline option or with the command 'benchmark on;' from the > SQL command prompt. It will time each SQL command without including the > overhead of isql/dbaccess/sqlcmd startup and connection overhead that using > timex would include. Sqlcmd is available for download from the IIUG > Software Repository. > > Art S. Kagel > Or you use datetimes and intervals in SQSL, eg LET start_time=CURRENT; <your sql here>; DISPLAY CURRENT-start_time; LET start_time=CURRENT; <some other sql here>; DISPLAY CURRENT-start_time; <etc> you can take the idea further and have total script times, intermediate times, and can even time prepare and execution times (have a look at the PREPARE and EXECUTE statements) >>Platform: AIX V5.3, IDS 9.40FC6, ISQL 7.32 >> >>Logged in as: informix >>export LIBPATH=$INFORMIXDIR/lib:$INFORMIXDIR/lib/esql: >>$INFORMIXDIR/lib/tools >> >>I'm attempting to use timex and isql to time queries from the command >>line. isql < my myquery.sql runs ok, but if I do this: >> >>0> timex isql >>exec(): 0509-036 Cannot load program isql because of the following >>errors: >> 0509-150 Dependent module libifsql.so could not be loaded. >> 0509-022 Cannot load module libifsql.so. >> 0509-026 System error: A file or directory in the path name does >>not exist. >> >>real 0.00 >>user 0.00 >>sys 0.00 >> >>Hmmm. not good. timex must need something for it's environment. >>libifsql.so is actually located in $INFORMIXDIR/lib/esql. What should I >>change to get this to work? >> >>TIA DT -- Ciao, Marco ______________________________________________________________________________ Marco Greco /UK /IBM Standard disclaimers apply! Structured Query Scripting Language http://www.4glworks.com/sqsl.htm 4glworks http://www.4glworks.com Informix on Linux http://www.4glworks.com/ifmxlinux.htm
Hi,
Alternatively:
Write your SQL script to a file and run it as follows
timex dbaccess dbname < filename
It should run and return the values from timex.
Rick
Marco Greco wrote:
> Art S. Kagel wrote:
>
>> Dave Thacker wrote:
>>
>> Get Jonathan Leffler's sqlcmd package. It has a benchmark mode
>> (enabled with the -B commandline option or with the command 'benchmark
>> on;' from the SQL command prompt. It will time each SQL command
>> without including the overhead of isql/dbaccess/sqlcmd startup and
>> connection overhead that using timex would include. Sqlcmd is
>> available for download from the IIUG Software Repository.
>>
>> Art S. Kagel
>>
>
> Or you use datetimes and intervals in SQSL, eg
>
> LET start_time=CURRENT;
> <your sql here>;
> DISPLAY CURRENT-start_time;
> LET start_time=CURRENT;
> <some other sql here>;
> DISPLAY CURRENT-start_time;
> <etc>
>
> you can take the idea further and have total script times, intermediate
> times, and can even time prepare and execution times (have a look at the
> PREPARE and EXECUTE statements)
>
>>> Platform: AIX V5.3, IDS 9.40FC6, ISQL 7.32
>>> Logged in as: informix
>>> export LIBPATH=$INFORMIXDIR/lib:$INFORMIXDIR/lib/esql:
>>> $INFORMIXDIR/lib/tools
>>>
>>> I'm attempting to use timex and isql to time queries from the command
>>> line. isql < my myquery.sql runs ok, but if I do this:
>>>
>>> 0> timex isql
>>> exec(): 0509-036 Cannot load program isql because of the following
>>> errors:
>>> 0509-150 Dependent module libifsql.so could not be loaded.
>>> 0509-022 Cannot load module libifsql.so.
>>> 0509-026 System error: A file or directory in the path name does
>>> not exist.
>>>
>>> real 0.00
>>> user 0.00
>>> sys 0.00
>>>
>>> Hmmm. not good. timex must need something for it's environment.
>>> libifsql.so is actually located in $INFORMIXDIR/lib/esql. What should I
>>> change to get this to work?
>>> TIA DT
>
>
>
>