Re: Fw: How to Retrieve Table Name from Statement Handle

2008-05-08 Thread Bart Lateur
On Wed, 7 May 2008 12:41:01 -0700 (PDT), Lamb Joseph wrote: I will have to break apart the SQL statement with a regex and store it that way. Thanks for the input. More input: take a look at Ovid's article Lexing Your Data on perl.com, at

Fw: How to Retrieve Table Name from Statement Handle

2008-05-07 Thread Lamb Joseph
To answer you question, for an Oracle environment I would like $sth-{TABLENAME} to contain a list. my $tablename = $sth-{TABLENAME} -[0] = First table $tablename $sth-{TABLENAME} -[1] = Second table The $tablename value will be schema.tablename format. For example: schema.narf

Fw: How to Retrieve Table Name from Statement Handle

2008-05-07 Thread Lamb Joseph
I will have to break apart the SQL statement with a regex and store it that way. Thanks for the input. Joseph Lamb - Forwarded Message From: Jonathan Leffler [EMAIL PROTECTED] To: Lamb Joseph [EMAIL PROTECTED] Cc: dbi-users@perl.org Sent: Wednesday, May 7, 2008 12:22:06 PM Subject:

Re: Fw: How to Retrieve Table Name from Statement Handle

2008-05-07 Thread Jonathan Leffler
On Wed, May 7, 2008 at 12:37 PM, Lamb Joseph [EMAIL PROTECTED] wrote: To answer you question, for an Oracle environment I would like $sth-{TABLENAME} to contain a list. my $tablename = $sth-{TABLENAME} -[0] = First table $tablename $sth-{TABLENAME} -[1] = Second table The $tablename

Re: Fw: How to Retrieve Table Name from Statement Handle

2008-05-07 Thread Steve Baldwin
You may be able to use the explain plan functionality in Oracle to obtain the tables participating in a SELECT statement. Steve On Wed, 2008-05-07 at 12:48 -0700, Jonathan Leffler wrote: On Wed, May 7, 2008 at 12:37 PM, Lamb Joseph [EMAIL PROTECTED] wrote: To answer you question, for an