Row - HidekiHrk/JLDB GitHub Wiki

Home

Properties:

  • table : the Table object wich the row is stored;

  • row_id : the row id. each row have a unique id in the table; type: int;

  • dict : a dict with all row properties (including the data stored on row);

Each row can modify freely its data by accessing them like properties. Example:

row1 = table1.get_first(name="foo")
print(row1.name) # foo
row1.name = "bar"
print(table1.get_first(name="foo")) # None
print(table1.get_first(name="bar")) # <jldb.__main__.Row object at 0x00000000000>

Methods:

  • save() : commits the row to the table;

  • delete() : deletes the row from the table;