You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@superset.apache.org by "motionrus (via GitHub)" <gi...@apache.org> on 2023/08/30 13:53:26 UTC
[GitHub] [superset] motionrus opened a new issue, #25125: DataType JSON auto convert to String
motionrus opened a new issue, #25125:
URL: https://github.com/apache/superset/issues/25125
To reproduce the problem, I created a dataset from the abc table
```
create table public.abc
(
source_id varchar(255) not null,
json jsonb,
constraint pk_source_id primary key(source_id)
);
insert into abc (source_id, json) VALUES (1, '{"key": "value"}');
```
then I checked that my column type was json.
![Снимок экрана 2023-08-30 в 16 42 04](https://github.com/apache/superset/assets/14940768/cce23570-0ae4-4c16-a7ab-e48de6ec50cd)
and when I get an object for handlebars, I get very upset that I get a string instead of an object.
![Снимок экрана 2023-08-30 в 16 48 04](https://github.com/apache/superset/assets/14940768/d2311587-6b44-420e-ba2f-79261df24f47)
and I can't do ``` <li>{{this.json.key}}</li> ```` because there is a string in the json
```json
{"source_id":"1","json":"{'key': 'value'}"}
```
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org
Re: [I] DataType JSON auto convert to String [superset]
Posted by "gregersn (via GitHub)" <gi...@apache.org>.
gregersn commented on issue #25125:
URL: https://github.com/apache/superset/issues/25125#issuecomment-1777156242
After digging a bit in the source code, I found that this is related to the lack of support for complex data types as can be seen here:
https://github.com/apache/superset/blob/419d12281612bd0cd1bdca121efbb39f02d7cb1e/superset/utils/core.py#L158
and here:
https://github.com/apache/superset/blob/419d12281612bd0cd1bdca121efbb39f02d7cb1e/superset/result_set.py#L155
And is mentioned in related issue, here: https://github.com/apache/superset/issues/19388
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org
Re: [I] DataType JSON auto convert to String [superset]
Posted by "albuscopperplate (via GitHub)" <gi...@apache.org>.
albuscopperplate commented on issue #25125:
URL: https://github.com/apache/superset/issues/25125#issuecomment-2036392400
would be great this to work!
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org