Skip to Content

Archived discussions are read-only. Learn more about SAP Q&A

line number in sap hana studio

Hello People !

How do i make the line number visible in sap hana studio or is there any shortcut to jump directly to line # in sap hana studio ?

i am writing a script . the partial code of the script is below

*************************************************************************************


DECLARE CURSOR GUID_CURSOR FOR

   SELECT DISTINCT MDB_GUID

   FROM :VAR_ALL_DATA

    WHERE CNT >1;

 

 

  FOR C_MDB_GUID AS GUID_CURSOR

  DO

   FOR COLUMN_NAME IN :VAR_ALL_OUTPUT_COLUMNS

   DO

    IF (:COLUMN_NAME = 'MDB_GUID') THEN

     EXECUTE IMMEDIATE 'INSERT INTO C5210998.#LTT_BR_OUT(MDB_GUID) VALUES('''||:C_MDB_GUID||''');'

    ELSE

    {

     FOR VAR_SOURCE IN VAR_ALL_SOURCE

     DO

     

       SELECT :COLUMN_NAME INTO VAR_COL_VALUE FROM :VAR_ALL_DATA

        WHERE MDB_GUID = :C_MDB_GUID

        AND SOURCE = :VAR_SOURCE;

      

       IF ( :VAR_COL_VALUE IS NOT NULL)THEN

        BREAK;

       END IF;

     END FOR;

    

     UPDATE C5210998.#LTT_BR_OUT SET :COLUMN_NAME = :VAR_COL_VALUE

      WHERE MDB_GUID = :C_MDB_GUID;

    }

    END IF;

   

   END FOR;

  END FOR;

*************************************************************************************

and i am receiving error at line 34 which is DECLARE CURSOR LINE. it is normal declare statement nothing advanced and i found nothing wrong in declairation. below is the error message

*******************************

Internal deployment of object failed;Repository: Encountered an error in repository runtime extension;Internal Error:Deploy Calculation View: SQL: sql syntax error: incorrect syntax near "CURSOR": line 34 col 4 (at pos 989)nSet Schema DDL statement: set schema "SYSTEM"nType DDL: create type

******************************

can anyone please suggest if i am doing something worng in the script ?

:VAR_ALL_DATA has a simple select statement and i checked running it to see it is resulting records

thanks for the help !!

Tags:
Former Member
Not what you were looking for? View more on this topic or Ask a question