Skip to content
GitLab
Explore
Sign in
You need to sign in or sign up before continuing.
Changes
Page history
oldb snippets: check existence of dp, write dp value
authored
Jul 03, 2023
by
Marcus Schilling
Show whitespace changes
Inline
Side-by-side
KnowledgeBase/CII.md
View page @
46c75a0e
...
@@ -1903,9 +1903,17 @@ Type "help", "copyright", "credits" or "license" for more information.
...
@@ -1903,9 +1903,17 @@ Type "help", "copyright", "credits" or "license" for more information.
```
plaintext
```
plaintext
>>> elt.oldb.CiiOldbGlobal.set_write_enabled(True)
>>> elt.oldb.CiiOldbGlobal.set_write_enabled(True)
>>> if not oldb.data_point_exists(Uri("cii.oldb:/ccs/tst/tmp1")):
>>> oldb.create_data_point_by_value (Uri("cii.oldb:/ccs/tst/tmp1"), "my text")
>>> oldb.create_data_point_by_value (Uri("cii.oldb:/ccs/tst/tmp1"), "my text")
```
```
… and, to write a datapoint:
```
plaintext
>>> elt.oldb.CiiOldbGlobal.set_write_enabled(True)
>>> oldb.get_data_point (Uri("cii.oldb:/ccs/tst/tmp1")).write_value("my text")
```
… and, to read a datapoint:
… and, to read a datapoint:
```
plaintext
```
plaintext
...
...