• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

A rather strange null error

 
Ranch Hand
Posts: 58
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I have this prepared statement
SQLDef.BUSEMPINFO_INSERT=
INSERT INTO busempinfo (lastupdate) VALUES (?)
but when i use this on my Java servlet like this
pstmt = conn.prepareStatement(SQLDef.BUSEMPINFO_INSERT);
pstmt.setString(1,fdate.format(now));
pstmt.executeUpdate();
i got an error anException type. which just state
null. It did not go to my SQLException catch.
what seems to be cause this null error. When i turn to the mysql client an run this insert
INSERT INTO busempinfo(lastupdate) VALUES('2003-01-01');
i worked fine. Please help me out anyone. Thanks...
 
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi,
use exception.printStacktrace() method in all the
catch block. it will give u some hint bt the exception
HTH,
asharaf
 
Pay attention! Tiny ad!
a bit of art, as a gift, the permaculture playing cards
https://gardener-gift.com
reply
    Bookmark Topic Watch Topic
  • New Topic