see read_sql_query() doc : https://pandas.pydata.org/pandas-docs/stable/reference/api/pandas.read_sql_query.html
columns can be type-casted using the cast_columns_to_types dictionary argument : { 'column_sql_name' : 'type'}. For 'type', see dtype String Aliases : https://pandas.pydata.org/docs/user_guide/basics.html#basics-dtypes
columns can be type-casted using the cast_columns_to_types dictionary argument : { 'column_sql_name' : 'type'}.
For 'type', see dtype String Aliases : https://pandas.pydata.org/docs/user_guide/basics.html#basics-dtypes
"""
#import pandas.io.sql as psql
importpandasaspd
...
...
@@ -105,8 +106,10 @@ def formatCSV(mydataframe):
defformatJSON(dataframe):
"""
Internal method to output dataframe as JSON
https://pandas.pydata.org/pandas-docs/version/0.23/generated/pandas.DataFrame.to_json.html : says that date may be sent like epoch in ms
commentoncolumnnavigoviz.ship.captain_listis'JSON array of various captains having sailed on the same ship through sources, with the frequecy of appearance in documents';
commentoncolumnnavigoviz.ship.mindateis'First date of appearance of this ship in the sources';
commentoncolumnnavigoviz.ship.maxdateis'Last date of appearance of this ship in the sources';