Obj.dbEditUpdateSQL = "(|;)UPDATE Field(s) SET Field(s) = [[New value]] WHERE Field1 = {{Criteria value}} AND Field2 = {{Criteria value1}}"
Keyword
Description
Field
Field is the fields of the dbSQL result and not the displayed order.
[[New value]]
[[New Value]] are to be filled with the User input(s). The [[..]] wrappers are non-negotiable. User is responsible for the correct wrappers for the different data types.
{{Criteria value}}
{{Criteria value}} is the existing value of the record that governs which field to update. The {{..}} wrappers are non-negotiable. User is responsible for the correct wrappers for the different data types.
QuickProp Keyword Abbreviation
euq
Remarks
dbEditUpdateSQL and dbEditAddSQL has a delimiter prefix. The second character of the delimter prefix delimits the multiple SQLs used in multiple tables editing. See the "edit two tables" example below. This delimiter prefix is not available to the grid editing as an internal delimiter of chr(7) is used. The reason of using a non-printable character is to allow ';' to be used in the field.
[[field]] and {{field}} - Field is the field ordinals of the dbSQL and not the displayed order. See Special example.
{{Criteria value}} is the existing value of the record that governs which field to update and [[New Value]] will be filled with the User input(s). The [[..]] and {{..}} wrappers are non-negotiable. User is responsible for the correct wrappers for the different data types.
Example
X.dbEditUpdateSQL = "UPDATE [Order Details] SET [Order Details].quantity = [[4]] WHERE [Order Details].orderid = {{0}} AND [Order Details].productid = {{1}}"
X.dbEditUpdateSQL = "UPDATE Products SET Productname='[[1]]',SupplierID=[[2]],CategoryID=[[3]] WHERE (ProductID={{0}})"
X.dbEditUpdateSQL = "UPDATE FRANK SET YEAR='[[0]]', MONTH='[[MONTH]]', CITY='[[City]]', name='[[NAME]]',ADDRESS='[[ADDRESS]]',TAX=[[TAX]] WHERE CITY='{{City}}' and name='{{Name}}' and Address='{{Address}}' and TAX={{Tax}}"