File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Statement Vs PreparedStatement ?

 
Seshaiah Chimata
Greenhorn
Posts: 5
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,

Why do we need Statement when there is a more benefit with PreparedStatement (Pre-compiled in database after first hit)?
I mean in which scenario we should use Statement interface instead of PreparedStatement interface ?

Thanks,
Seshu
 
Wendy Gibbons
Bartender
Posts: 1107
Eclipse IDE Oracle VI Editor
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
can you do DDL in prepared statements eg create table?
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic