Changes between Version 13 and Version 14 of Docs/Prog/Manual/ApplicationLibraries/lib825db
- Timestamp:
- 10/23/25 07:42:23 (3 weeks ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
Docs/Prog/Manual/ApplicationLibraries/lib825db
v13 v14 52 52 } 53 53 }}} 54 This instantiates either a CDBMySQL object for MySQL or a CDBSQLite. The CDB* pointer appDB is assigned to the created object. 54 55 55 56 Existing apps with have sql execute statements such as: … … 67 68 }}} 68 69 To support both SQLite and MySQL the brackets must be removed from table and field names in SQL statements. 70 71 Existing apps may have code such as: 72 {{{ 73 string sql = "INSERT INTO [Trucks] ([ID],[TareWt]) VALUES ('" + truckID +"'," + IntToStr(tare) + ");"; 74 if (rc_is_okay(db.execute(sql)) == false) { 75 DrawErrorBox("Cannot insert record", 4); 76 } 77 }}} 78 Replace with: 79 {{{ 80 string sql = "INSERT INTO Trucks (ID,TareWt) VALUES ('" + truckID +"'," + IntToStr(tare) + ");"; 81 if (appDB->execute(sql) == false) { 82 DrawErrorBox("Cannot insert record", 4); 83 } 84 }}} 69 85 70 86 Existing apps will have code such as:
![(please configure the [header_logo] section in trac.ini)](/chrome/site/cardinal.gif)