TinyDB – The matches() Query The matches() query matches the data from a JSON file with a given condition (in the form of a regular expression) and returns the results accordingly. It will return a blank value if the condition does not match with the data in the file. Syntax The syntax of TinyDB matches() […]
Author Archives: user
TinyDB – Logical Negate Logical Negate works as an inverse logical gate. It will match the documents that don”t match the given query. In simple words, it will display the opposite meaning of the given command. Syntax The syntax of TinyDB Logical Negate is as follows − db.search(~(Query().field) Here, field represents the part of data […]
TinyDB – The exists() Query TinyDB provides an advanced query called exists() that checks the existence of data in a JSON file. The exists() query actually tests the availability of a subfield data from a JSON file. The exists() query works on the basis of a Boolean condition. If the subfield exists (i.e., BOOLEAN TRUE), […]