1. Anuncie Aqui ! Entre em contato fdantas@4each.com.br

[SQL] Using endDelimiter with one-line SQL sentences

Discussão em 'Outras Linguagens' iniciado por Stack, Novembro 7, 2024 às 12:32.

  1. Stack

    Stack Membro Participativo

    Im trying to make the following code work in my deployment:

    --liquibase formatted sql
    --changeset test:1 endDelimiter:/

    CREATE OR REPLACE PUBLIC SYNONYM XXXX FOR XXX;
    /
    GRANT EXECUTE ON XXXX TO XXXX;
    /
    --rollback not required;


    The code snippet above results in a ORA-00933 error (SQL not properly ended).

    The deployment tool needs the code from procedures, functions and triggers to be in separate .sql files from that of grants, create, replace, etc.

    My goal is to standarize the use of the delimiter "/" for all files.

    Is there a way to achieve using endDelimiter:/ with semi-colons or would it be better to just use endDeliimter with those pieces of code which has stored logic like procedures, functions, etc?

    Thanks

    Continue reading...

Compartilhe esta Página