Solved

TIBQuery.SQL does not understand "set term" command?

Posted on 2007-11-26
3
385 Views
Last Modified: 2012-06-27
Hello :-)

I created quite a complex stored procedure which I want to execute dynamically using TIBQuery.
Within my stored procedure I use "SET TERM ^ ; " command.

The stored procedure is correct and works fine when executed from EMS.

When executed from TIBQuery it crashes with error message which mentions "TERM"

Thank you very much :-)

panJames
0
Comment
Question by:panJames
  • 2
3 Comments
 
LVL 21

Accepted Solution

by:
developmentguru earned 500 total points
ID: 20349873
Show the SQL that you place in the TIBQuery to execute your stored procedure.  It should look something like:

Exec MyStoredProc

  I know that SET TERM can't be used everywhere.  If you are attempting to use the code of your stored procedure, verbatim, inside your TIBQuery then it likely will not work.  If you are calling the stored procedure correctly using your TIBQuery then The stored procedure would need to be looked in to.  In order to determine the problem it would help to see how it is called and the stored procedure itself.

  Without seeing any of that I can only say that you could fall back on some old fasioned debugging techniques.  You could use Binary Deconstruction on your stored procedure to see if something inside your procedure is causing the error.  Comment out half of it and see if the error still happens (last half).  If it does then comment out the last half of what is left, etc until the error does not happen.  If you are able to comment out all of the code and the error still happens then something must be wrong with how it is being called... perhaps a component update is needed... Until more testing is done (or more code shown) it will be difficult to be any more help.

Let me know.
0
 

Author Comment

by:panJames
ID: 20350272
This is DDL query and starts this way:

SET TERM ^ ;
CREATE PROCEDURE ABC (

and it looks like TIBQuery does not like
"SET TERM"

panJames
0
 

Author Comment

by:panJames
ID: 20350585
I think I solved this problem.

TIBQuery.ParamCheck := False;

and simple do not use 'SET TERM' at all.

Now it works fine.

panJames
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

A lot of questions regard threads in Delphi.   One of the more specific questions is how to show progress of the thread.   Updating a progressbar from inside a thread is a mistake. A solution to this would be to send a synchronized message to the…
This article explains how to create forms/units independent of other forms/units object names in a delphi project. Have you ever created a form for user input in a Delphi project and then had the need to have that same form in a other Delphi proj…
Internet Business Fax to Email Made Easy - With  eFax Corporate (http://www.enterprise.efax.com), you'll receive a dedicated online fax number, which is used the same way as a typical analog fax number. You'll receive secure faxes in your email, f…
Many functions in Excel can make decisions. The most simple of these is the IF function: it returns a value depending on whether a condition you describe is true or false. Once you get the hang of using the IF function, you will find it easier to us…

863 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

24 Experts available now in Live!

Get 1:1 Help Now