Programming Guide : 5. Working with a Database : Conceptual Background
 
Share this page                  
Conceptual Background
Most OpenROAD applications provide users with an interface to a relational DBMS that uses the four primary data manipulation statements—select, update, insert, and delete—to enable the following operations:
Retrieve data for viewing or updating
Add new data
Delete existing data
OpenROAD also provides access to the database through the DataStream system class without directly executing an SQL statement. DataStream's subclass, SQLSelect, provides greater power and flexibility than the primary data manipulation statements. In particular, SQLSelect objects are useful for:
Letting users step backwards through the retrieved data or to move directly to a specific row
Creating dynamic queries when the target fields or variables are unknown until runtime
Changing queries at runtime (for example, modifying the where and order by clauses)
SQLSelect objects interact dynamically with the database, verifying that the names and data types of the columns in their target list are the same as those coded when the application was developed.
QueryObject objects, a subclass of the SQLSelect class, also support partitioning a query and enable update, insert, and delete operations on dynamically retrieved data.
For a detailed discussion and an example of using an SQLSelect to retrieve data, see How You Can Access a Database with DataStream Objects. For a detailed discussion and an example of using a query object to change data, see How You Can Use Query Objects.