prorm API Reference
    Preparing search index...

    Interface StoredProcedureOptions

    Options for creating a stored procedure

    interface StoredProcedureOptions {
        name: string;
        schema?: string;
        params?: StoredProcedureParam[];
        body: string;
        returnType?: string;
        language?: string;
        replace?: boolean;
        ifNotExists?: boolean;
        comment?: string;
    }
    Index
    name: string

    Name of the stored procedure

    schema?: string

    Schema where the stored procedure belongs

    Input parameters

    body: string

    The procedure body (SQL statements)

    returnType?: string

    Return type (for functions)

    language?: string

    Language (SQL, PL/pgSQL, etc.)

    replace?: boolean

    If true, uses CREATE OR REPLACE

    ifNotExists?: boolean

    If true, does not throw if already exists

    comment?: string

    Optional comment