I can't seem to be able to create migration with simplest sql to create PostgreSQL procedure.
Error is:
Exception data: Severity: ERROR SqlState: 42601 MessageText: syntax error at end of input Position: 186 File: scan.l Line: 1184 Routine: scanner_yyerror
Sql code works fine when executed in pgAdmin.
protected override void Up(MigrationBuilder migrationBuilder)
{
var sp = @"CREATE PROCEDURE reset_primary_holder()
LANGUAGE SQL
BEGIN ATOMIC
SELECT * FROM id.users;
END;";
migrationBuilder.Sql(sp);
}
What am I doing wrong?