Using SBN expressions in queries

The following examples show how to use SBN expressions in queries.

Examples

A select statement to retrieve a specific customer record might include a constant customer record CU_NO for that record:

select * FROM CUSTOMERS WHERE CU_NO = '12345678'

With SBN, you can use a more flexible approach by assigning the constant value of CU_NO to a custom component property. See “Custom properties”. Assuming that value ‘12345678’ was assigned to a property CustNo, the select statement with the dynamic expression looks like:

select * FROM CUSTOMERS WHERE CU_NO = '[REF.CustNo]'

You can use any of the Sybase ETL functions inside the SBN expression. The following statement returns the same record using a value of “1234” for CustNo1 and a value “4567” for CustNo2:

select * FROM CUSTOMERS WHERE CU_NO = '[uConcat (REF.CustNo1, REF.CustNo2)]'