Skip to content

Line/Column numbers #21

@bryanburgers

Description

@bryanburgers

Does postgres return line/column numbers in its parse tree? If it does, is it possible to put them in the JSON output?

I would like to use node-pg-query-native to split a complex schema creation file into its individual commands, but can't just use query.split(/;/g) because it contains plpgsql functions. Since pg-query-parser can't deparse some of the types that I'm using (e.g., DROP statements). If the libpg_query output included line number/column number, I could use this parser to determine when commands start and end, then use that information to split out the original queries from the original sql file.

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