Error - permission is denied for FJSONParser and General JSON question

Hi,

1) I am getting this permission denied error when trying to load JSON data with the parser option. I have checked the user_functions table and the grants table and everything seems to be set up ok with the right permissions.

Any ideas?

2)  Do I always have to use the JSON parser using the COPY command in order to process the JSON further or can I load the JSON data to a staging table and then use the JSON parser to process it further?

All the examples I have seen use the JSON parser at the initial load i.e.

copy target from source parser FJSONParser();

Thanks,

Comments

  • Hi,

    Resolved! - It turns out you need to reference the public schema -

    set search_path to  your_schema,public;

    Just putting it here for anyone else.

Leave a Comment

BoldItalicStrikethroughOrdered listUnordered list
Emoji
Image
Align leftAlign centerAlign rightToggle HTML viewToggle full pageToggle lights
Drop image/file