0

I am try to execute the stored procedure using liquibase having the / delimiter in
sql file the Database Is db2. The problem is it is giving me error as DB2 SQL Error: SQLCODE=-104, SQLSTATE=42601, SQLERRMC=END-OF-STATEMENT;demoTable = ((demovar;) not able to understand the cause as all other stored procedure in same file get executed well..

using the following changeset

and demo.sql has the stored procedure and set demovar declare in it any suggestion what is cause

Abhishek
  • 101
  • 3
  • 8

1 Answers1

1

Your error message says:

DB2 SQL Error: SQLCODE=-104, SQLSTATE=42601

-104 represents SQL0104N and here is explanation.

SQL0104N An unexpected token token was found following text. Expected tokens may include: token-list.
https://www.ibm.com/support/knowledgecenter/en/SSEPGG_11.5.0/com.ibm.db2.luw.messages.sql.doc/com.ibm.db2.luw.messages.sql.doc-gentopic1.html#sql0104n

Explanation

A syntax error in the SQL statement or the input command string for the SYSPROC.ADMIN_CMD procedure was detected at the specified token following the text text. The text field indicates the 20 characters of the SQL statement or the input command string for the SYSPROC.ADMIN_CMD procedure that preceded the token that is not valid.

As an aid, a partial list of valid tokens is provided in the SQLERRM field of the SQLCA as token-list. This list assumes the statement is correct to that point.

This message can be returned when text is passed to the command line processor (CLP) in command mode and the text contains special characters that are interpreted by the operating system shell, such as single or double quotes, which are not identified with an escape character.

The statement cannot be processed.

So you may need to follow "User response" section of the page and correct SQL statement in demo.sql.

Hope this helps.

hidehy
  • 179
  • 5