Here I come with a small tip for generating native SQL from your “PreparedStatement” object, which is as simple as that.
This is my java code.
And, if you want to print the original native SQL of the above “PreparedStatement”, just do a simple thing.
Here I just print the “PreparedStatement” objct, pst, in the console.
That’s it. The output will be