Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

result.next_id/result.next_state is not a known variable pg(syntax) #489

Closed
Labels
bugSomething isn't working
@diraneyya

Description

Bug report

I just started using this extension as a replacement for UniqueVision's LSP extension, which seems abandoned and no longer maintained. I may have to go back to that extension, though, if this does not work.

Describe the bug

I am developing an extension with this table definition:

create table if not exists _fetch_cycle_continuation_data (
 next_id bigint,
 next_state jsonb null default '{}'::jsonb
 constraint abstract_no_data check(false) no inherit
);

It is an abstract table that I inherit from.

In my procedure I have the following variable and assignment:

create or replace function continue_fetch_cycle_prototype (
 previous_step fetch_cycle_buffer_prototype
) returns _fetch_cycle_continuation_data language plpgsql as $prototype$
declare
 result _fetch_cycle_continuation_data := null;
begin 
 result.next_id := 0;
 ...
 result.next_state := '{}'::jsonb

The error messages are of the likes of:

`result.next_id` is not a known variable pg(syntax)
`result.next_state` is not a known variable pg(syntax)

Expected behavior

No syntax complaint is expected since the code is correct and works.

System information

I am using this vscode extension without Supabase, in my own PostgreSQL (v17.4) database.

  • OS: Linux
  • Browser (if applies) NA
  • Version of supabase-js: NA
  • Version of Node.js: NA

Additional context

My config:

{
 "$schema": "https://pgtools.dev/latest/schema.json",
 "vcs": {
 "enabled": false,
 "clientKind": "git",
 "useIgnoreFile": false
 },
 "files": {
 "ignore": []
 },
 "linter": {
 "enabled": true,
 "rules": {
 "recommended": true
 }
 },
 "db": {
 "host": "127.0.0.1",
 "port": 5432,
 "username": "postgres",
 "password": "xxxxxxxxxxxxx",
 "database": "aajobs",
 "connTimeoutSecs": 10,
 "allowStatementExecutionsAgainst": ["127.0.0.1/*", "localhost/*"]
 }
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions

        AltStyle によって変換されたページ (->オリジナル) /