Quantcast
Channel: SmartClient Forums
Viewing all articles
Browse latest Browse all 4756

How to Unescape $values or $criteria attribute in DataSource Operation Binding?

$
0
0
Let's assume a simple datamodel, I have classes that implement a scheduleable interface, ISchedule. The ISchedule interface defines a startDate, and endDate.


simple datasource descriptor:

Code:

<DataSource
    ID="planner"
        serverType="sql"
        tableName="planner"
 
>
    <fields>
 <field name = "name" title="Name" type = "text">       
<field name = "pk" title="entityId" type = "text">
<field name = "name" title="Name" type = "text">
        <field        name = "startDate" title = "startDate" type = "dateTime" />
        <field name="endDate"        title="EndDate" type="datetime"/>
        <field name="quantity"        title="Quantity"  type="integer"/>

    </fields>
    <operationBinding operationId="fetchData" operationType = "FETCH" >
            <customSQL>
                    SELECT (startDate, endDate)
                    FROM $values.tableName AS Planner
                WHERE pk = Planner.pk
            </customSQL>
    </oprationBinding>
</DataSource>

In the server logs example output:

FROM 'businesPlanner' AS Planner

===================================

Intent:

FROM businessPlanner AS PLANNER

How to prevent the $values.tableName from being sanitized?

====================================
v10.0p_2015-04-01/FULL Deployment (

Firefox 37+

Viewing all articles
Browse latest Browse all 4756

Trending Articles