From 7b7a67afb5b1b3178bfd68f7446321954c9639a8 Mon Sep 17 00:00:00 2001 From: WANG MINGMING Date: Fri, 30 Sep 2022 11:38:30 +0800 Subject: [PATCH] Update 38-schemaless-opentsdb-telnet.md --- .../en/07-data-in/38-schemaless-opentsdb-telnet.md | 14 ++++++++++---- 1 file changed, 10 insertions(+), 4 deletions(-) diff --git a/docs/en/07-data-in/38-schemaless-opentsdb-telnet.md b/docs/en/07-data-in/38-schemaless-opentsdb-telnet.md index c35463dc37..6938d0741c 100644 --- a/docs/en/07-data-in/38-schemaless-opentsdb-telnet.md +++ b/docs/en/07-data-in/38-schemaless-opentsdb-telnet.md @@ -52,7 +52,13 @@ You can use any client that supports the http protocol to access the RESTful int ``` ### Insert Example -- curl --request POST http://127.0.0.1:6041/opentsdb/v1/put/telnet/test --user "root:taosdata" --data-binary "sys.if.bytes.out 1479496100 1.3E0 host=web01 interface=eth0" - -### Query Example with SQL -- select * from `sys.if.bytes.out` where host="web01" and interface="eth0" +```bash +curl --request POST "$TDENGINE_CLOUD_URL/opentsdb/v1/put/telnet/?token=$TDENGINE_CLOUD_TOKEN" --data-binary "sys 1479496100 1.3E0 host=web01 interface=eth0" +``` + +## Query Example with SQL +`sys` is the super table name. +you can filter data by tag, like:`where host="web01"`. +```bash +curl -L -d "select * from .sys where host=\"web01\"" $TDENGINE_CLOUD_URL/rest/sql/test?token=$TDENGINE_CLOUD_TOKEN +``` -- GitLab