We made the first step in the direction to popular JSON format.
Valentina SQL already did have extentions
- SELECT … FOR XML
- SELECT … FOR REPORT
Now we adding one more: SELECT … FOR JSON.
We have upload 5.5b21 build where this feature is introduced. It works in same way as FOR XML. In the result you get cursor with a single record and a single TEXT field.
Example:
SQL query ‘SELECT * FROM tblCustomer FOR JSON’ returns
{ "name": "tblCustomer", "fields": ["fldFirstName","fldLastName","fldCountry","fldPhone"], "records": [ ["Peter","Thomas","Germany","111111"], ["Brian","Hill","USA","222222"], ["Simon","Smith","Italy","333333"], ["Chris","Maxwell","France","444444"], ["Greg","Silver","France","555555"], ["Jerry","Lucas","USA","666666"], ["Mark","Lord","Canada","777777"] ] }