By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
424,851 Members | 1,109 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 424,851 IT Pros & Developers. It's quick & easy.

Simple SQLj question ....

P: n/a
UDB V8.1.3 on XP. While trying out SQLj procedures, I just 'compile'
my stored procedure code (by command sqlj program-name.sqlj) and run
it. That's it. So, how and when is db2profc and all the other commands
needed? The stored procedure seems to run without executing these
commands as well. In fact, I experience no difference between methods
of preparing JDBC or SQLj procedures other than the fact that JDBC
procedures are compiled with 'javac' command (as opposed to 'sqlj'
command for SQLj procedures.

What am I missing.

TIA
Raquel.
Nov 12 '05 #1
Share this Question
Share on Google+
2 Replies


P: n/a
Raquel wrote:
UDB V8.1.3 on XP. While trying out SQLj procedures, I just 'compile'
my stored procedure code (by command sqlj program-name.sqlj) and run
it. That's it. So, how and when is db2profc and all the other commands
needed? The stored procedure seems to run without executing these
commands as well. In fact, I experience no difference between methods
of preparing JDBC or SQLj procedures other than the fact that JDBC
procedures are compiled with 'javac' command (as opposed to 'sqlj'
command for SQLj procedures.

What am I missing.

TIA
Raquel.


Trying to remember way back with my teeny brain, but I believe that if
you don't run db2profc to customize the generated serialized profiles
that the sqlj command produces, you're effectively running your stored
procedure as a JDBC stored procedure.

db2profc is the command that actually creates and binds the static
packages in the database, theoretically increasing the execution of any
SQL in your SQLJ procedure. Otherwise everything reverts back to being
dynamically prepared and executed.

I /think/ that's what you're missing. But I reserve the right to be wrong :)

Dan
Nov 12 '05 #2

P: n/a
Thanks Ron. Believe you are correct.

Regards,
Raquel.
Nov 12 '05 #3

This discussion thread is closed

Replies have been disabled for this discussion.