Hi Amar

I think, your expression, iNNSO_SalesOrderGraphPerCust.parmCustAccount() returns a single Customer Account Number. Obviously, that is not what you want.

You might be able to get more values, if you build the string of numbers before applying to your range value. like:

   int i;
   str s, rangevalue;
   for (i=1; i<10;i++)
   {
       s+=strfmt("%1,",i);
   }
   rangevalue=substr(s,1,strlen(s)-1);

The rangevalue will correspond to the output from your method

iNNSO_SalesOrderGraphPerCust.parmCustAccount()

Sample ranges:

"*00*" - all account numbers having string "00" in the number
"400*" - all account numbers starting with the string "400"
"4001,4002" - Either 4001 or 4002
"4001..4006,4006-5000" - either between range 4001 and 4006, or between range 4006 and 5000


Be sure, not to build a too long string, else you end up with a SQL error.

The problem with this kind of building a string is, the size of the WHERE expression of the SQL Statement, thereby running into a limitation of the underlying database's query handler..

The Dialog field value could be like the sample ranges above.

:-)

From: "Amar Kumar Senapati" <[EMAIL PROTECTED]>
Reply-To: [EMAIL PROTECTED]
To: <[EMAIL PROTECTED]>
Subject: [development-axapta] How to filter data when lookup?
Date: Fri, 31 Oct 2003 18:17:36 +0800

Hi All,
I have problem in filtering record in my report query.
I am using a dialog field for filtering my outputted data in my report.
I am using this code in my fetch method in my report.

this.query().dataSourceTable(tableNum(Custtable)).addRange(fieldNum(Cust
Table,accountnum)).value(iNNSO_SalesOrderGraphPerCust.parmCustAccount())
;

where iNNSO_SalesOrderGraphPerCust is the class object where I have the
dialog method.

But I am only able to filter one record like one customer account. When
I enter more than one customer account using commas ( How we use in
filter conditions for reports), then my above code is not working . It
always takes the first customer and outputted the report.

Can anyone help me , what I should modify in my code so that it will
filter for all records inputted in the Dialog field.

Thanks
Regards
Amar









_________________________________________________________________ Få alle de nye og sjove ikoner med MSN Messenger http://messenger.msn.dk/



Yahoo! Groups Sponsor ADVERTISEMENT
click here


Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service.

Reply via email to