Please be aware that the content in SAP SQL Anywhere Forum will be migrated to the SAP Community in June and this forum will be retired.


I'm trying to upgrade an 11 database to 16. I have tried via command prompt using both the dbupgrad command and also dbunload.

At this point I am getting an error:

SQL error (-30000) – RAISERROR Executed: Invalid Sybase Driver, must use ‘SQL Anywhere 11’ driver

I have also tried this via the GUI and get the same error with the following additional information:


Any help would be appreciated.



asked 28 Aug '15, 09:46

FELLA's gravatar image

accept rate: 0%


That message looks like it is coming from a user-written RAISERROR statement inside custom SQL code, somewhere in a stored procedure, trigger, or other block of code inside the database. -30000 is not an "official" SQLCODE value, it is a custom user-created value.

Do you get this error message when trying to run dbupgrad or dbunload, or do you get it afterwards when you try to connect to the database?

WAG: You may have a "login procedure" with some code that needs to be modified or removed.

(28 Aug '15, 11:27) Breck Carter
Replies hidden

I get the error message when trying to run dbupgrad or dbunload. I can't connect either, with the same issue, stating I must use ‘SQL Anywhere 11’ driver. I can start the database using the dbsrv command

(28 Aug '15, 11:40) FELLA

I can start the database using the dbsrv command.

But can you also connect to the database on v11? And if so, do you have a login procedure in place, as Breck has asked?

(28 Aug '15, 13:01) Volker Barth

It appears that this is indeed a custom error thrown. One of the procedures restricts connections to anything that is not version 11. I've been told I have to unload the database and search for the error code to discover which procedure it is. Any advice on this would be appreciated.

(01 Sep '15, 04:55) FELLA

Any advice on this would be appreciated.

Then I guess you will have to use v11's dbunload to generate an according reload.sql file (e.g. "%SQLANY11%\bin32\dbunload -n -c <yourconnectionstring> reload.sql") and then search through that to find the according procedure - or simply use Sybase Central to inspect the procedures's code...

As this procedure seems to influence each connection, I would follow Breck's hint that there is a particular "login procedure" in place - what does the following reveal when used within DBISQL?

select connection_property('login_procedure');

If that does not return NULL, it should tell you the name of the according procedure which might have to be modified (or any procedure called by that one).

(01 Sep '15, 05:25) Volker Barth

I have located the procedure that was causing the issue. There was a custom procedure that replaces the standard login procedure "sp_login_environment" in the sybase db options. Thanks for your help.

permanent link

answered 01 Sep '15, 05:34

FELLA's gravatar image

accept rate: 0%

converted 01 Sep '15, 05:34

Your answer
toggle preview

Follow this question

By Email:

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



Answers and Comments

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text]( "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:


question asked: 28 Aug '15, 09:46

question was seen: 2,164 times

last updated: 01 Sep '15, 05:34