• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 406
  • Last Modified:

Get the SQL String From a JDBC Prepared Statement

I've instantiated a PreparedStatement object and set all its string parameters but I want to get a look at the complete SQL string before i send it to the database. toString() just prints out the object reference. Does anyone know how?
0
comahony
Asked:
comahony
  • 2
1 Solution
 
TimYatesCommented:
Don't think you can with Java...

Maybe if you turn on SQL logging on your database, that would show it?

Tim
0
 
NachiapCommented:
yeah you cant see the full query in java ..
0
 
TimYatesCommented:
Wow! Thanks for the points :-D

Good luck in the future,

Tim.
0

Featured Post

Never miss a deadline with monday.com

The revolutionary project management tool is here!   Plan visually with a single glance and make sure your projects get done.

  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now