cancel
Showing results for 
Search instead for 
Did you mean: 

Remote Procedure Call not firing

0 Kudos

We use remote procedure calls all over our application.  All of them are defined in n_tr.

When we designed this section of the application, it was back when we were using ASA6.  Calls worked flawlessly.

Now we've moved up to SQL Anywhere 12.  Been there for some time.  Then I get the call that this particular module isn't working correctly.

I start digging through the code and notice that certain aspects of what is supposed to be handled through the stored procedure isn't happening.

So I put a simple print statement in the stored procedure.  Ran this module again.  Statement never printed.  Hmmmm.

Let me try the debugger.  So I put some debugger stops in this stored procedure over in SQL Anywhere.  Ran it for all connections.  Figured that it would fire the procedure, and since I'm testing locally on my machine, it would stop at the point it hit the first debug point and the application would wait for me to step though the procedure, then hand control back to the application.

But again.  Nothing.  It's like it gets to that call, and just steps past it.

I read that since the RPC doesn't return any arguments, to set it up as a subroutine.  It had been set up as a function.  So I converted the RPC call to a Subroutine.  Ran it again.  Absolutely nothing.  Gets to the call, and just keeps on going.  Doesn't stop at any of the debug points and never hits the print statement.

And for the record, There are other RPC's that are firing just fine.  We have one specially that fires when you switch the project you're in.  That way it sets up all the connection level variables on each project.

Does anybody have any thoughts on what else I might look at that could be causing this?  Just find it strange that this was working just fine, and now under SQL Anywhere 12 it just seems like it is silently failing.

Any ideas on this would be greatly appreciated.

TIA for everyone's help!!

Jeff Gibson

Intercept Solutions

Nashville, TN

Accepted Solutions (0)

Answers (2)

Answers (2)

Former Member
0 Kudos

Possibly a datatype mismatch in the arguments/method definition?   Any "weird" datatypes in there, like long binary or something?

-Paul-

Former Member
0 Kudos

We have one specially that fires when you switch the project you're in.  That way it sets up all the connection level variables on each project.

I can't say that I fully understand that - and it suggests that you have your own terminology.  Switching projects in PB classic IDE shouldn't "fire" anything related to the current database connection.  The term "module" is also likely something for which you have your own definition.  So - it would help your readers if you could use standard PB terms and define your environment a little more completely (classic app, .net app, etc.).

A long shot - your description leads me to suspect that somewhere in the application code a transaction object (sqlca or some other) is recreated not with n_tr but with transaction.

Note that you can create application-controlled breakpoints using a construct like:

if <some condition> then

debugbreak()

end if

That will let you run in the debugger with a breakpoint that can be controlled by user action or time (or anything else you can evaluate).  As opposed to clicking on the continue button hundreds of times.

0 Kudos

Sorry Scott.

I should have clarified.  When I said switching projects, I meant that within our application.  The projects managers jump from project to project and it sets up new values for all the connection level variables.

As for module, I am specifically talking about the area in our application that lets the end user enter companies into our application.  So the nomenclature is from the aspect of an end user.  I should have probably worded the question differently.

I'll do some scans to see if n_tr is getting replaced at any point.  I don't think it is but you can never say never.  I keep thinking though that this is an issue with SQL Anywhere 12 and how it works with a PB10 application.

Thanks for the suggestions on setting conditional break points.

Jeff Gibson

Intercept Solutions

Nashville, TN