Please be aware that the SAP SQL Anywhere Forum will be shut down on August 29th, 2024 when all it's content will be migrated to the SAP Community.

Hello,

Assume, we have a procedure in SA 10.0.1.4225 (remote database is SA11 or SA12):

CREATE PROCEDURE "remote_user"."p_test_remote_xml"(IN @s CHAR(30000))
result(r CHAR(30000)) at 'main_database;;dba;sp_test_remote_xml'

We get an error when we try to pass an argument with more than 254 characters:

The string is too long (parameter 1)
SQLCODE=-973, ODBC 3 State="54000"

However, documentation says nothing about such limitation (or at least I can't find anything about that). Besides, the problem is only with the argument and not with return string.

Is it possible in some other way to pass a string with more than 254 characters to remote procedure? Or using web service is the only way?

asked 15 Nov '11, 07:46

Arthoor's gravatar image

Arthoor
1.4k355267
accept rate: 11%

edited 17 Nov '11, 13:40

Mark%20Culp's gravatar image

Mark Culp
25.0k10142298


From the 12.0.1 "What's new" docs:

IN parameters of data types LONG VARCHAR, LONG BINARY, and LONG NVARCHAR are now allowed in remote procedure calls.
A remote procedure call can now contain IN parameters of data types LONG VARCHAR, LONG NVARCHAR, and LONG BINARY. In addition, parameters of data types VARCHAR, NVARCHAR, and BINARY are no longer restricted to 255 bytes. See Create remote procedures.

Therefore I would assume (but I'm not sure!) that in 10.0.1, you have run into an existing limitation...

permanent link

answered 15 Nov '11, 08:46

Volker%20Barth's gravatar image

Volker Barth
40.5k365556827
accept rate: 34%

edited 15 Nov '11, 08:47

Yes, you have hit a known limitation with remote procedures that was eventually resolved in 12.0.1. Sadly, the documentation is not clear enough about the restriction.

permanent link

answered 17 Nov '11, 13:28

Karim%20Khamis's gravatar image

Karim Khamis
5.7k53870
accept rate: 40%

Thank you both.

(18 Nov '11, 03:50) Arthoor
Your answer
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

Question tags:

×119
×70
×56

question asked: 15 Nov '11, 07:46

question was seen: 3,027 times

last updated: 18 Nov '11, 03:50