Skip to content

Column not found when using WITH ORDINALITY clause #1205

Closed
@boecklim

Description

@boecklim

Version

1.10.0

What happened?

When trying to generate a query using sqlc which includes WITH ORDINALITY then sqlc returns an error which says that the columns cannot be found.

Relevant log output

column "id" does not exist

Database schema

No response

SQL queries

SELECT td.id, td.rn FROM unnest(@foo::uuid[]) WITH ORDINALITY AS td(id, rn);

Configuration

No response

Playground URL

https://play.sqlc.dev/p/298dce5f371c9759abe7a5beb3d0e5b6ec2a4b4f9cb9cbf96a3d8e4404a7f744

What operating system are you using?

Linux

What database engines are you using?

PostgreSQL

What type of code are you generating?

Go

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions