Just making sure it's not a typo on the message :
>    range   = strfmt('(((Dimension == "P-001") || ((Dimension[2] ==
I guess Dimension should be Dimension[1].

Steeve...

--- In [email protected], "david santoso" 
<[EMAIL PROTECTED]> wrote:
>
> Hi All,
> 
> i wanna create querybuild datasource using OR for array fields
> 
> for ex :
> 
> show salestable with dimension[1] = 'P-001' or dimension[2] = 'Q-
001'
> 
> i've try with this code, but it didn't work.
> 
>     Query                       q;
>     QueryBuildDataSource        qbds;
>     QueryRun                    qr;
>     QueryBuildRange             qbr;
>     Range                       range;
>     ;
>     super();
> 
>     q = new query();
>     qbds = q.addDataSource(Tablenum(SalesTable));
>     qbr  = qbds.addrange(fieldId2ext(fieldnum
(SalesTable,Dimension),2));
>     range   = strfmt('(((Dimension == "P-001") || ((Dimension[2] ==
> "Q-001")))');
> 
> 
>     qbr.value(range);
>     qr = new queryrun(q);
>     SalesTable_ds.query(q);
>     SalesTable_ds.queryRun(qr);
> 
> Any Suggestion would be helpfull,
> 
> Thx
> 
> Davids
>


Reply via email to