Skip to content

SQLSTATE 42601 on CREATE OR REPLACE FUNCTION #174

@fedoreremin-btf

Description

@fedoreremin-btf

Describe the bug
When trying to execute create or replace function, it complains at SQLSTATE 42601

To Reproduce
execute

create or replace function concat(id int)
    returns text
    language plpgsql
    as
$$
declare
    name text;
begin
    select coalesce(last_name||' ', ''),
        coalesce(first_name||' ', ''),
        coalesce(middle_name||' ', '')
    into name
    from person
    where person.id = id;
    return trim(name);
end;
$$;

Expected behavior
Complete execution

Versions (please complete the following information):

  • OS Version: Arch Linux
  • sqls Version 0.2.27

Additional context

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions