Hari-Durai-Baskar opened a new issue, #15672:
URL: https://github.com/apache/druid/issues/15672
example code:
import druidapi
import os
if 'DRUID_HOST' not in os.environ.keys():
druid_host=f"http://localhost:8888"
else:
druid_host=f"http://{os.environ['DRUID_HOST']}:8888"
print(f"Opening a connection to {druid_host}.")
druid = druidapi.jupyter_client(druid_host)
display = druid.display
sql_client = druid.sql
query = """WITH HumidChange AS (SELECT device_id,__time,humidity,humidity -
LAG(humidity) OVER (PARTITION BY device_id ORDER BY __time) AS humid_change
FROM thermal_log) SELECT d.device_id,d.device_name,tc.__time,tc.humidity AS
current_humidity, tc.humid_change FROM devices d JOIN HumidChange tc ON
d.device_id = tc.device_id WHERE tc.humid_change >= 10"""
display.sql(query)
--
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: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]