borland Packages  Class Hierarchy  jbcl.dataset Package  Index 

MetaDataUpdate interface

borland.jbcl.dataset.MetaDataUpdate

About the MetaDataUpdate interface

Variables  

The MetaDataUpdate interface defines constants used with the metaDataUpdate property of the QueryDataSet and ProcedureDataSet components. Its constants specify whether metadata discovery should be performed (or not) when executing a query or stored procedure against a SQL server database. From the JBuilder UI Designer, select the metaDataUpdate property of the StorageDataSet component and select which constant to use.

If the driver used to connect to a SQL database does not support the metaData functions used by this package, you may get an error message indicating that edits to the data cannot be saved because none of its updatable columns have a table name. In such cases, try setting the metaDataUpdate property of the QueryDataSet or ProcedureDataSet to MetaDataUpdate.NONE. This bypasses the step of automatic querying for meta data information, however, in order for the data to be updatable, this information must be available. For Column components, set the rowID, precision, scale, and searchable properties. For QueryDataSet and ProcedureDataSet components, set the tableName and schemaName properties.

For more information on metadata, see the Metadata and how it is obtained topic in the Database Application Developer's Guide.


MetaDataUpdate variables

Variables defined in this interface


MetaDataUpdate variables

ALL

  public static final int ALL = 31
This constant is the default and specifies that the open of the DataSet will automatically override the following settings:

NONE

  public static final int NONE = 0
This constant is used to specify that the open of the DataSet is not to override the above stated properties. You must specify the values for these properties for any persistent Column components in the StorageDataSet.

For more information on persistent columns, see the Persistent columns topic in the Database Application Developer's Guide.

PRECISION

  public static final int PRECISION = 4
Specifies that the precision property of persistent columns should be overridden by the value detected in the driver's metadata.

ROWID

  public static final int ROWID = 2
Specifies that a query should be analyzed for updatability. If set, the query string may be automatically changed to include columns that can be used to identify a row in a table. The rowID property is set or reset on all columns, overriding the settings in any persistent columns. The default resolver (QueryResolver) needs this information to make update queries. This constant has no effect for ProcedureDataSet components.

SCALE

  public static final int SCALE = 8
Specifies that the scale property of persistent columns should be overridden by the value detected in the driver's metadata.

SEARCHABLE

  public static final int SEARCHABLE = 16
Specifies that the searchable property of persistent columns should be overridden by the value detected in the driver's metadata.

TABLENAME

  public static final int TABLENAME = 1
Specifies that the tableName and schemaName properties of the StorageDataSet and any persistent columns should be set when opening the DataSet. The default resolver (Queryresolver), needs this information to make update queries. This constant has no effect for ProcedureDataSet components.