Skip Headers

Oracle® Objects for OLE Developer's Guide
10g Release 1 (10.1)

Part Number B10118-01
Go to Documentation Home
Home
Go to Book List
Book List
Go to Table of Contents
Contents
Go to Master Index
Master Index
Go to Feedback page
Feedback

RecordSource Property

See Also
Example
Applies To

Oracle Data Control

Description

The SQL select statement to be used to create the data control's RecordSet. Read/write at design time and run time.

Usage

oradata1.RecordSource = [ SQL SELECT Statement ]

Remarks

The SQL statement must be a SELECT statement; otherwise an error is returned. Features such as views, synonyms, column aliases, schema references, table joins, nested selects, and remote database references can be used freely; object names are not modified in any way.

The updatability of the resultant dynaset depends on the Oracle SQL rules of updatability, on the access you have been granted, and on the ReadOnly property. In order to be updatable, three conditions must be met:

  1. the SQL statement must refer to a simple column list or to the entire column list (*),
  2. the SQL statement must not set the read-only flag of the options argument, and
  3. Oracle must permit ROWID references to the selected rows of the query.
Any SQL statement that does not meet these criteria is processed, but the results are not updatable and the dynaset's Updatable property returns False.

Changing this property does not take effect until a Refresh method is sent to the data control.

You can use SQL bind variables in conjunction with the OraParameters collection.

If this property is NULL or empty, then an OraDynaset object is not created, but OraSession, OraConnection, and OraDatabase objects are created for the data control. This behavior enables access to these objects prior to creation of a dynaset. For example, a NULL RecordSource might be used to instantiate the database object for the purpose of adding parameters. RecordSource can then be set at run time, making use of the automatic binding of database parameters.

Changing this property and calling Refresh Method of RecordSet Property will create a new dynaset object, but the old dynaset continues to be available for use until all references to it are removed.

Data Type

String