Translating with DrWatson… this can take a few seconds the first time.
This is a genuine, complex translation. DrWatson protects commands, error codes, and log output while naturally translating the surrounding text. It’s translated once and saved.
Antony U P — — source: Usenet: comp.databases.informix
Hi,
Is it possible use the SYSTEM SPL to find the OS details using 'uname'
command. I am using 7.31.UD7
I tried this:
> create procedure getosname()> SYSTEM 'uname';
> end procedure;
Routine created.
> execute procedure getosname();
Routine executed.
How do I get the output to be printed other than redirecting it to a
temp file and then getting the data from there. Using UDR is not
possible as this is 7.31.
Is there any other way to get the platform type using a SPL..
Thanks
Antony
Not that I can think of.
Why does the platform type of the database server matter?
Perhaps run some sql to stick this into a table somewhere
that you can query rather than doing the uname each time?
X=`uname -a`
echo 'insert into table x values ("'${X}'";' | dbaccess mydb
stick this in a table
We use strictly necessary cookies to make this site work. With your
consent we’d also use optional cookies for analytics and marketing. You can accept all,
reject all, or choose. Read our Cookie Policy.