From OpenSCADAWiki
Jump to: navigation, search

Table 5. Actions over the table.

Operation Action
Interrogation

Request: command "get": <get path="/fld_teg" user="user" cols="0;2" rows="100;1000"/>

To get columns 0-2 and rows of them from 100 to 1000 table.

Result: Confirmation with the data of the table or an error message. The result is formed in the form:

<get path="/fld_teg" user="user" cols="0;2" rows="100;1000" rez="0">
<list id="0" tp="str">
<el id="100">Sat Feb 21 18:04:16 2004</el>
</list>
<list id="1" tp="str">
<el id="100">SYS</el>
</list>
<list id="2" tp="str">
<el id="100">*:(TSYS)Broken PIPE signal allow!</el>
</list>
</get>
Adding of the row

Request: command "add": <add path="/fld_teg" user="user"/>
Result: confirmation or an error message.

Inserting of the row

Request: command "ins": <ins path="/fld_teg" user="user" row="3"/>

To insert the string in position 3. Command does not work when attribute key is set!

Result: confirmation or an error message.

Deleting of the row

Request: command "del": <del path="/fld_teg" user="user" row="3"/> or <del path="/fld_teg" user="user" key_id="Test"/> for the key mode

To remove the string in position 3 or string in the position where the id column value is "Test".

Result: confirmation or an error message.

Moving of the row

Request: command "move": <move path="/fld_teg" user="user" row="3" to="5"/>

To move the string from position 3 to position 5. Command does not work when attribute key is set!

Result: confirmation or an error message.

User command of the row

Request: command "{user}": <{user} path="/fld_teg" user="user" row="3"/> or <{user} path="/fld_teg" user="user" key_id="Test"/> for the key mode

To send a {user} command for position 3 or string in the position where the id column value is "Test".

Result: confirmation or an error message.

Changing of the row

Request: command "set": <set path="/fld_teg" user="user" row="3" col="id">Test</set> or <set path="/fld_teg" user="user" key_id="Test" col="id">Test1</set> for the key mode

To set the cell's value in row 3 and column "id" to "Test" or set of the column named "id" of the row to the position where the id column value is "Test" to value "Test1". Practically, this command renames a key element of the specified row.

Result: confirmation or an error message.