Hello,

I have the following SQL statement:

IF ::conn.TransactionCount > 0 THEN ROLLBACK; ENDIF;

It works perfect from ARC but using it from a remote computer via Advantage StreamlineSQL ODBC, it throw an error "2141 Parameter missing".

Any clues?

Thanks,

Titus

asked 09 Dec '15, 14:20

Titus's gravatar image

Titus
466611
accept rate: 0%

edited 09 Dec '15, 14:21


Looks like the ODBC driver interprets the : as a parameter. You might try using a UDF:

create function getTransactionCount()
returns integer
begin
  return ::conn.TransactionCount;
end;
and then change your statement to
IF getTransactionCount() > 0 THEN ROLLBACK; ENDIF;

link

answered 09 Dec '15, 14:52

Joachim%20Duerr's gravatar image

Joachim Duerr
8.7k1031133
accept rate: 18%

Indeed it did the trick.

Note: a Data Directory is required.

I suppose that this is a bug in ODBC and I am not the single one who reached it. There is any chance to be solved?

(09 Dec '15, 16:15) Titus

in order to get it solved you need to contact SAP.

(09 Dec '15, 16:49) Joachim Duerr

What programming language are you using? In Delphi there is an option (called ParamCheck to enable/disable parameter handling with colons).

(09 Dec '15, 18:17) Jens Mühlenhoff
Your answer to the original question.
If responding to a request for additional information, please edit the question or use the comment functionality.
toggle preview

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text](http://url.com/ "Title")
  • image?![alt text](/path/img.jpg "Title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported

Tags:

×43
×30

Asked: 09 Dec '15, 14:20

Seen: 1,503 times

Last updated: 09 Dec '15, 18:17

Advantage Developer Zone Contact Us Privacy Policy Copyright Info


Powered by Advantage Database Server and OSQA
Disclaimer: Opinions expressed here are those of the poster and do not necessarily reflect the views of the company.