You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I used pandas.read_sql_table() to fetch a table, in which there is a JSON column. In the returned dataframe, the double quotations wrapping the keys and values are all changed to single quotations.
Example of returned dataframe:
id
name
1
{'first': 'Anna', 'last': 'Smith'}
However, JSON standards requires double quotation, on top of that, other Python package like json doesn't recognize JSON with single quotations.
Code Sample
Problem description
I used
pandas.read_sql_table()
to fetch a table, in which there is a JSON column. In the returned dataframe, the double quotations wrapping the keys and values are all changed to single quotations.Example of returned dataframe:
However, JSON standards requires double quotation, on top of that, other Python package like
json
doesn't recognize JSON with single quotations.Expected Output
Output of
pd.show_versions()
The text was updated successfully, but these errors were encountered: