Win a copy of Functional Reactive Programming this week in the Other Languages forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Correct approach ? Stored Proc (returning cursor) Vs Prepared statment

 
prasad kulkarni
Ranch Hand
Posts: 66
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I have lot of select queries to integrate with my java code.

I have two options to select within :

1. Store procedure which returns cursor
2. Prepared statements

Which one should I use ? Which one is the fastest and a correct approach?

Can java experts please put some pros and cons of both approaches?
 
Jan Cumps
Bartender
Posts: 2602
13
C++ Linux Netbeans IDE
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
1 is proprietary , 2 is portable across databases.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic