SQLOrderADO
Use this component to run a single SQL query on an order, passing order parameters to the query.
Intended use: Order Processing pipeline, Accept stage.
Configuration Values
You can determine the query the SQLOrderADO component runs by setting component properties. Use the following boxes on the SQL Order (ADO) tab of the Component Properties dialog box to determine this information.
Box | Description |
Connection String | The connection string to connect to the database. This may be a full connection string or a name in a connection map. If blank, the default connection string is used. |
Query | The full SQL text of the query this component will execute, or the name of a query whose full SQL text is defined in the Global.asa file in the QueryMap key. |
Parameter List | The parameters the component passes to the query. Separate multiple parameters with a single space. The following are the allowed parameters:
count Passes the query the number of line items on the order. order.fieldname Passes the value of the specified field in the order form. sum.fieldname The query receives the sum of a particular field on the order. sumq.fieldname Passes the sum times the respective quantities. |
Child Object Name | The name of a field that receives the data. The component uses the field only if the Use Child Object check box is selected. |
Use Child Object | Indicates whether or not the component is to use the object specified in the Child Object Name box. If the check box is not selected, the component assumes there is no child object. |
Values Read
The SQLOrderADO component reads the following values from the indicated dictionaries.
Key | Dictionary | Description |
DefaultConnectionString |
Context | Optional. The key in the Application dictionary containing the default connection string. |
ConnectionStringMap |
Context | Optional. The map in which to look up the name of a mapped connection string. |
QueryMap |
Context | Optional. A reference to a dictionary containing a query map. |
Values Written
None.
Remarks
The SQLOrderADO component runs a SQL query once per order, passing the specified order parameters to the query. The component uses ActiveX Data Objects (ADO) to interface with the data source, and therefore supports COM+ transactions.
The connection string must include either the full connection string (the data source name (DSN), database login ID, and database password) or the name of a named connection stored in the connection map.