Closed rmalpe closed 1 year ago
import pandas as pd from questdb.ingress import Sender
df = pd.DataFrame({ 'id': pd.Categorical(['toronto1', 'paris3']), 'temperature': [20.0, 21.0], 'humidity': [0.5, 0.6], 'timestamp': pd.to_datetime(['2021-01-01', '2021-01-02'])'})
with Sender('localhost', 9009) as sender: sender.dataframe(df, table_name='sensors')
Oops! Thanks for the catch!
Done here: https://github.com/questdb/py-questdb-client/pull/48
import pandas as pd from questdb.ingress import Sender
df = pd.DataFrame({ 'id': pd.Categorical(['toronto1', 'paris3']), 'temperature': [20.0, 21.0], 'humidity': [0.5, 0.6], 'timestamp': pd.to_datetime(['2021-01-01', '2021-01-02'])'})
with Sender('localhost', 9009) as sender: sender.dataframe(df, table_name='sensors')