Please start any new threads on our new
site at https://forums.sqlteam.com. We've got lots of great SQL Server
experts to answer whatever question you can come up with.
Author |
Topic |
nhell
Starting Member
6 Posts |
Posted - 2009-04-13 : 02:40:12
|
Hello. Can anyone help me with this?Date--------Movementtype---In-----Out----OnHand03/29/09----Receive--------20------0-------5503/28/09----TransferOUT-----0-----10-------3503/23/09----TransferOUT-----0------5-------4503/22/09----Adjustment----(50)-----0-------5003/21/09----Receive--------20------0------13003/20/09----TransferOut-----0-----20------11003/19/09----Receive--------30------0------13003/18/09----Adjustment---(100)-----0------10003/16/09----Receive--------10------0-------10I have a procedure arrange in descending order by date, it selects all transactions made by an item in warehouse. [In] is the quantity received and out is the quantity removed from the storage. "OnHand" is a calculated value. I use this expression on "OnHand":=Sum(Fields!In.Value)-Sum(Fields!Out.Value)-RunningValue(Fields!In.Value, Sum,Nothing)+RunningValue(Fields!Out.Value, Sum, Nothing)+Fields!In.Value-Fields!Out.ValueI got wrong results because I only manage to get the running value of the "OnHand" column. The tricky part is the "Adjustment" value of "Movement Type" column. I just want to know if the possibility of doing this in reporting services is higher than getting the value in SQL server. Regards,Nhell |
|
|
|
|