• 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

setBinaryStream supported in jdk1.3

 
Ranch Hand
Posts: 100
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Can any one please tell me whether setBinaryStream of prepared statement is supported in jdk1.3?If not what is the method that is supported similar to setBinaryStream functionality.

Since i I am using this setBinaryStream of prepared statement to insert a file into the blob column of the database. It workis fine in jdk1.6 but not in jdk1.3(file is not inserting) and doesnt give any error also. Kindly help me in this.
 
Sheriff
Posts: 22784
131
Eclipse IDE Spring VI Editor Chrome Java Windows
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Go to the Javadoc page of PreparedStatement (by clicking on the word).
Scroll down to the method list.
Click on the method (there are three of them though).
Check at the bottom of the method description. Does it have a "Since:" part? If so then it exists since that version of Java. If it doesn't it was available from the start.
 
shyamkumar bopannachengalaiah
Ranch Hand
Posts: 100
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
ok fine. But when I try ti insert the file into the blob using jdk1.3 and setBinary Stream method I am not able to insert the file.


But If i run same code using jdk1.6, I am able to insert the file into the blob successfully.
 
shyamkumar bopannachengalaiah
Ranch Hand
Posts: 100
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

ok fine. But when I try ti insert the file into the blob using jdk1.3 and setBinary Stream method I am not able to insert the file.


But If i run same code using jdk1.6, I am able to insert the file into the blob successfully. why I am not able to do so in jdk1.3?

 
Java Cowboy
Posts: 16084
88
Android Scala IntelliJ IDE Spring Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

shyamkumar bopannachengalaiah wrote:But when I try ... I am not able to insert the file.


What exactly does that mean? Does your code compile? Does it run? Do you get an error message, maybe with a stack trace? Just saying "it doesn't work" is useless.
 
Rob Spoor
Sheriff
Posts: 22784
131
Eclipse IDE Spring VI Editor Chrome Java Windows
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
What arguments are you passing?

If you've checked the Javadoc you will find three overloaded versions of that method. Only the one that takes an int, InputStream and int is supported before Java 6.
 
I am Arthur, King of the Britons. And this is a tiny ad:
a bit of art, as a gift, that will fit in a stocking
https://gardener-gift.com
reply
    Bookmark Topic Watch Topic
  • New Topic