Saturday 15 February 2014

google apps script - Using the JDBC Prepared Statement setNull() function -


I have a Google Apps script which is connected via JDBC from Google Cloud SQL example. I am using a prepared statement, and when I am trying to set a zero value, I am in trouble. To set any other type of value, you just do:

  Preparation .setflot (3, mflfloiter);   

But I can not get set to work. It is considered to be taking Java data type as an argument.

I have tried the following:

  readyStatement.setNull (4, "java.sql.Types.DECIMAL"); ReadyStatement.setNull (4, java.sql.Types.DECIMAL); & Lt; - How would you do this in Java, I believe readyStatement.setNull (4); ReadyStatement.setNull (4, faucet); PreparedStatement.setNull (4, "zero");   

This may have been either a "server error, please try again after a while", or "anything like" method (class) (class) can not be found in the Settlement ( Number, zero) "depending on what I try.

That's why I'm just working instead of setting things to 0 rather than zero, but it would be good to have this option!

What do I think, the second parameter of hope is a complete

I think this is a good candidate for an issue report, should be "ENUM" for the list of options in the JDBC service. If you open one, please link the comments Please, please share.

Now, due to the lack of proper ENUM, you should try different integers there. I think you will be lucky with some efforts, eg. < Pre class = "lang-js prettyprint-override"> L (4, 1); // or ready Sthitibddhta. Setnl (4, 2); // and so on ..

No comments:

Post a Comment