Symphony Framework
DataSelect Class
Members 
Symphony.Harmony Namespace : DataSelect Class
The DataSelect class enables SQL style queries againt a various database technologies.
Object Model
DataSelect ClassDataObjectBase Class
Syntax
Remarks
The DataSelect class allows you to interogate a data source to retreive matching records. The class accepts a standard SQL select command, the target Symphony Data Object. The logic to execute the select command on the data can be run locally in process or remotely via Symphony Bridge.

You must have a valid DBConnector object to inject into the object.

The SQL command is parsed and translated into the required underlying data source options. The select is then performed on the data source and the resuting data returned as a Generic List of DataObjectBase types

The following SQL structures are supported. The case of the commands, field, operators and conectors is not important. The case of any values is unless you first execute the DBConnector.SetCaseSensitivity method:

Select fields from a data source.

SELECT field_name [,field_name] FROM table

SELECT * FROM table

SELECT TOP # field_name [,field_name] FROM table

The WHERE clause is used to select only those records that fulfil; a specified criteria.

SELECT field_name, [field_name] FROM table WHERE field_name OPERATOR value [CONNECTOR field_name OPERATOR value]

Opertators in the WHERE clause

Connectors in the WHERE clause

For exmaple;

SELECT field_name, [field_name] FROM table WHERE field_name = value AND field_name = value

SELECT * FROM table WHERE field_name != value OR field_name != value

SELECT field_name, [field_name] FROM table WHERE field_name <> value AND field_name <> value

SELECT field_name, [field_name] FROM table WHERE field_name < value OR field_name > value

SELECT field_name, [field_name] FROM table WHERE field_name BETWEEN value AND value

SELECT field_name, [field_name] FROM table WHERE field_name LIKE 'value'

SELECT field_name, [field_name] FROM table WHERE field_name LIKE :1

Positional values can be assigned to the WHERE clause fields.

The ORDER BY key word is used to sort the results set by one or more columns. By default records are sorted in ascending order. To sort records in descending order use the DESC keyword

SELECT field_name [,field_name] FROM table ORDER BY field_name [,field_name] [ASC|DESC]

Inheritance Hierarchy

System.Object
   System.Collections.Generic.List<T>
      Symphony.Harmony.DataSelect

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2

See Also

Reference

DataSelect Members
Symphony.Harmony Namespace