You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@iotdb.apache.org by "MRIIOT (via GitHub)" <gi...@apache.org> on 2024/02/27 03:49:12 UTC
[I] [Bug] Python client 'insert_record' not working. [iotdb]
MRIIOT opened a new issue, #12087:
URL: https://github.com/apache/iotdb/issues/12087
### Search before asking
- [X] I searched in the [issues](https://github.com/apache/iotdb/issues) and found nothing similar.
### Version
Running 1.3.0-standalone in Docker. Tried `apache-iotdb 1.3.0` Python client. No records were inerted into database.
```python
from iotdb.Session import Session
from iotdb.template.MeasurementNode import MeasurementNode
from iotdb.template.Template import Template
from iotdb.utils.BitMap import BitMap
from iotdb.utils.IoTDBConstants import TSDataType, TSEncoding, Compressor
from iotdb.utils.Tablet import Tablet
from iotdb.utils.NumpyTablet import NumpyTablet
import time
ip = "192.168.111.132"
port_ = "6667"
username_ = "root"
password_ = "root"
session = Session(ip, port_, username_, password_)
session.open(False)
sg = "root.sg_test_01"
ts = "root.sg_test_01.d_01.s_01"
d1 = "root.sg_test_01.d_01"
m1 = "s_01"
try:
session.set_storage_group(sg)
except Exception as e:
pass
if session.check_time_series_exists(ts) is False:
session.create_time_series(ts,
TSDataType.INT32,
TSEncoding.PLAIN,
Compressor.SNAPPY)
for i in range(10):
time.sleep(1)
session.insert_record(d1, i, [m1], [TSDataType.INT32], [i])
session.close()
```
### Describe the bug and provide the minimal reproduce step
Run above code.
### What did you expect to see?
Records in database.
```
IoTDB> select * from root.sg_test_01.d_01.s_01
+----+
|Time|
+----+
+----+
Empty set.
It costs 0.008s
```
### What did you see instead?
No records.
### Anything else?
_No response_
### Are you willing to submit a PR?
- [ ] I'm willing to submit a PR!
--
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: reviews-unsubscribe@iotdb.apache.org.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [I] [Bug] Python client 'insert_record' not working. [iotdb]
Posted by "MRIIOT (via GitHub)" <gi...@apache.org>.
MRIIOT closed issue #12087: [Bug] Python client 'insert_record' not working.
URL: https://github.com/apache/iotdb/issues/12087
--
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: reviews-unsubscribe@iotdb.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [I] [Bug] Python client 'insert_record' not working. [iotdb]
Posted by "MRIIOT (via GitHub)" <gi...@apache.org>.
MRIIOT commented on issue #12087:
URL: https://github.com/apache/iotdb/issues/12087#issuecomment-1965740343
Nevermind, using the query syntax incorrectly.
```
select s_01 from root.sg_test_01.d_01
```
--
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: reviews-unsubscribe@iotdb.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org