Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.server -> Prepared statement parameter values while tracing

Prepared statement parameter values while tracing

From: OcNavi <ocnavi_at_gmail.com>
Date: 5 Jul 2005 08:16:28 -0700
Message-ID: <1120576588.702365.247200@f14g2000cwb.googlegroups.com>


Hi all,
  first of all, sorry for my english, i'm spanish.

  I'm tracing the execution of some Prepared Statements sent through JDBC to an Oracle 9i Database. I'm using the usual tracing methods (enabling session trace and tkprof). The issue is that the value of the parameters is not shown in the trace file. I mean, in the trace file the SQL text is:
  SELECT *
  FROM
  table1 WHERE idtable1=:1

In my java code i'm using the prepared statements this way:   PreparedStatement ps = con.prepareStatement("SELECT * FROM table1 WHERE idtable1=?");
  ps.setInt(1, Integer.parseInt(id));//where id=3

so i expected to find
  SELECT *
  FROM
  table1 WHERE idtable1=3
in the trace file.

Is there a way to trace the statement showing the values of the parameters?

Thanks in advance. Received on Tue Jul 05 2005 - 10:16:28 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US