Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Selecting amounts

Status
Not open for further replies.

srvu

Programmer
Apr 29, 2008
49
US
I have records as below

claimline claimid benededuct maxoutaccrual Lifetimeaccrual date
1 81813 100 25 225 24-08-08
2 81813 0 25 325 27-08-08
3 81813R1 -100 -25 -325 02-09-08


Here records with claimid where R1 is present are reveresal claims

i need to determine the last claim line by finding the most-recent claim date and the highest claim line number . If lifetimeaccrual is zero or negative, need to work back to the next-highest claim line number. If all lines on the claim have zero or negative lifetimeaccrual amounts, again work back to the next-most-recent claim date and start again with the highest-numbered claim line.


we can select max(claimline) and select Lifetime but if amt is -ve or zero what is the function where we can get back to next highest claimline and date????

Thanks in advance



 
I don't know how you can do this in PowerCenter. It's not designed to back up.

"I think we're all Bozos on this bus!" - Firesign Theatre [jester]
 
Don't know if it will suit your needs, but the rank transformation is the one that will provide you with (multiple) hierarchies in your data. In your case you may need to use a multi-pass approach. Check out the documentation on this transformation. I have worked miracles with it in the past!

Ties Blom

 
i have filtered maxout and Lifetime amounts in Exp record by record by applying condition
maxout!=0 and maxout!=-maxout
and similar conditions to Lifetime

Now passed to Agg t/r
where i need to check max date and max claimline and select maxout at that point where date and claimline is max value.

In agg if i apply a condition like IIF(date=max(date)and claimline =max(claimline),maxout,0)

But result of this is coming as value "1.00" but value there is "10234.84"



 
I think you need to look up how a condition works in a aggregate expression. Your syntax looks way-off

Ties Blom

 
Atlast i have resolved the issue

I have filtered all the zero and negative values in exp,and selected Last(amount)

Thanks for support
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top