FORWARD TO from Sybase IQ to ASE fails [CR #539484]

Execution of a FORWARD TO command from Sybase IQ to Adaptive Server Enterprise using the ASEODBC driver fails with ASA Error -660 “The identifier that starts with ‘<identifier>’ is too long. Maximum length is 28.”

Workaround:

To avoid this problem, do one of the following after creating a remote Adaptive Server Enterprise server using either server class aseodbc or server class asejdbc and before executing a SQL statement that contains a string with double quotes against the remote server using the FORWARD TO statement:

  1. Change the double quotes to single quotes.

  2. Include the database option SET QUOTED_IDENTIFIER OFF before the SQL statement to be executed:

    FORWARD TO <remote server name> {
    SET QUOTED_IDENTIFIER OFF
    <SQL statement>
    } 
    
  3. Set the QUOTED_IDENTIFIER database option to OFF using a separate FORWARD TO statement:

    FORWARD TO <remote server name> { 
    SET QUOTED_IDENTIFIER OFF }