Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add support for editing JSON PostgreSQL datatype #29133

Open
qgib opened this issue Feb 19, 2019 · 5 comments
Open

add support for editing JSON PostgreSQL datatype #29133

qgib opened this issue Feb 19, 2019 · 5 comments
Labels
Data Provider Related to specific vector, raster or mesh data providers Feature Request

Comments

@qgib
Copy link
Contributor

qgib commented Feb 19, 2019

Author Name: Felipe Souza (@felkis)
Original Redmine Issue: 21315

Redmine category:data_provider/postgis


The error seems to occur when saving from qgis back to Postgresql.

I´m connecting to a Postgresql Database, opening a table that has a json field. I see the data, and I´m trying to add an extra letter to a field. (attachment print).

The way I see, it seems that QGIS is sending back data as "hstore", but the column from my table is json.

ERROR ALERT:
Error PostGIS when changing attributes: ERROR: column "info" is of type jsonb but expression is of type hstore
LINE 1: ...TE "geometria"."plan_perimetro_urbano" SET "info"=E'"bike"=>...
^
HINT: You will need to rewrite or cast the expression.



Related issue(s): #29128 (copied_to)
Redmine related issue(s): 21310


@qgib
Copy link
Contributor Author

qgib commented Feb 19, 2019

@qgib
Copy link
Contributor Author

qgib commented Feb 19, 2019

Author Name: Giovanni Manghi (@gioman)


  • status_id was changed from Feedback to Open
  • subject was changed from JSON column from a Postgresql Database is working to read information, but when editing the column and saving it, an error occurs to add support for editing JSON PostgreSQL datatype

@qgib
Copy link
Contributor Author

qgib commented May 16, 2019

Author Name: Felipe Souza (@felkis)


This can be a great tool when you don´t want the user to change the default data from your table, but you let them create filters.
Any news on this?
Thank you.

Felipe Souza wrote:

The error seems to occur when saving from qgis back to Postgresql.

I´m connecting to a Postgresql Database, opening a table that has a json field. I see the data, and I´m trying to add an extra letter to a field. (attachment print).

The way I see, it seems that QGIS is sending back data as "hstore", but the column from my table is json.

ERROR ALERT:
Error PostGIS when changing attributes: ERROR: column "info" is of type jsonb but expression is of type hstore
LINE 1: ...TE "geometria"."plan_perimetro_urbano" SET "info"=E'"bike"=>...
^
HINT: You will need to rewrite or cast the expression.


  • assigned_to_id was configured as Giovanni Manghi

@qgib
Copy link
Contributor Author

qgib commented May 17, 2019

Author Name: Giovanni Manghi (@gioman)


  • assigned_to_id removed Giovanni Manghi

@stev-0
Copy link
Contributor

stev-0 commented Oct 13, 2019

This is likely related to #29361

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Data Provider Related to specific vector, raster or mesh data providers Feature Request
Projects
None yet
Development

No branches or pull requests

2 participants