Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Set Analysis into backend Script ?

HI All,

I need to convert SetAnalysis into back end script...

if(DR_CR='D',

sum(OPENING)+

sum({<TD_DOC_DT={"<=$(=max(TD_DOC_DT))"},TD_DOC_DT_Year=,TD_DOC_DT_Month=,TD_DOC_DRCR_FLAG={'D'}>}TD_DOC_AMT)-

sum({<TD_DOC_DT={"<=$(=max(TD_DOC_DT))"},TD_DOC_DT_Year=,TD_DOC_DT_Month=,TD_DOC_DRCR_FLAG={'C'}>}TD_DOC_AMT)

regards,

Heather

5 Replies
Not applicable
Author

Heather, we need a little more information, are all the fields involved int he same table?

Not applicable
Author

2 tables

simondachstr
Luminary Alumni
Luminary Alumni

Hi Heather,

Where exactly lies your issue? What have you tried so far? At which step are you having problems?

Or do you simply hope we will do your job for free?

its_anandrjs

If they are not in same table take this fields in single table and then you are able to create the expression in the backend because SET expression not worked in the load script.

Regards

Anand

Not applicable
Author

HI All,

Actualling there only some customers having opening amount till Sep -2011 in One Table...

One Table:

COMP_CODE,

     ACNT_YEAR,

     CAL_YEAR,

     MAIN_ACNT_CODE,

     SUB_ACNT_CODE as [Customer No],

     SUB_ACNT_CODE as Custcode,

     OPENING,

     DR_CR

In another table:

TD_TH_SYS_ID,

TD_DOC_DT,

month(TD_DOC_DT) as TD_DOC_DT_Month,

year(TD_DOC_DT) as TD_DOC_DT_Year,

date(Date#(year(TD_DOC_DT)&'-'&month(TD_DOC_DT),'YYYY-MMM'),'MMM-YYYY') as TD_DOC_DTYearMonth,

TD_DOC_DRCR_FLAG,

TD_DOC_AMT,

TD_MAIN_ACNT_CODE,

[Customer No]

Here I have to add the opening balance to customers who are having DR_CR flag='D'  added, if DR_CR='C' is Subtracted....

ACtually this the Logic I am working in Set Analysis Coming Correct....

I need to implement in Back ENd Script Calaculation & I have to bring as Finally bone AMount to a Customer No...

And the If Customer have not DOne any transaction in Any month automtatically previous month Amount Should be Carry Forwarded....

please help , If you want I will post my qvw

also.....

Thanks,

Heather