Cumulative Condtional Functoid
Web Server forum
Back To The Forum Home!Search!Private Messaging System

Web Server Talk Web Server Talk > Web Servers reviews > BizTalk Server > BizTalk Server Tools > Cumulative Condtional Functoid




  Last Thread   Next Thread Next
  Show Printable Version Email this Page Subscribe to this Thread      Post New Thread    Post A Reply      

    Cumulative Condtional Functoid  
Adam


View Ip Address Report This Message To A Moderator Edit/Delete Message


 
02-08-04 01:43 PM

Here is a sample XML instance
<Availability_V1>
<Identification PurchaserIDNumber="1008" UserName="RICKMOLICA"
FromOrgID="C" DateCreated="20031022">
<Item ItemIDNo="1199" ItemDescription="x" PurchaserItemIDNo="253510"
PurchaserItemDescription="0">
<ShipWeek ShipWeek="200404" StartWeek="200340" HoldWeeks="5">
<RecordType RecordType="AA" UnitsAvailable="1" QtyAvailable="10"
OrderNumber="0" />
<RecordType RecordType="BA" UnitsAvailable="2" QtyAvailable="20"
OrderNumber="" />
<RecordType RecordType="PR" UnitsAvailable="3" QtyAvailable="30"
OrderNumber="" />
</ShipWeek>
<ShipWeek ShipWeek="200404" StartWeek="200352" HoldWeeks="">
<RecordType RecordType="AA" UnitsAvailable="1" QtyAvailable="11"
OrderNumber="" />
<RecordType RecordType="BA" UnitsAvailable="2" QtyAvailable="21"
OrderNumber="" />
<RecordType RecordType="PR" UnitsAvailable="3" QtyAvailable="31"
OrderNumber="" />
</ShipWeek>
<ShipWeek ShipWeek="200406" StartWeek="200401" HoldWeeks="">
<RecordType RecordType="AA" UnitsAvailable="1" QtyAvailable="12"
OrderNumber="" />
<RecordType RecordType="BA" UnitsAvailable="2" QtyAvailable="22"
OrderNumber="" />
<RecordType RecordType="PR" UnitsAvailable="3" QtyAvailable="32"
OrderNumber="" />
</ShipWeek>
</Item>
<Item ItemIDNo="2284" ItemDescription="y" PurchaserItemIDNo="0"
PurchaserItemDescription="Unable to map">
<ShipWeek ShipWeek="200414" StartWeek="200404" HoldWeeks="5">
<RecordType RecordType="AA" UnitsAvailable="2" QtyAvailable="20"
OrderNumber="0" />
<RecordType RecordType="BA" UnitsAvailable="3" QtyAvailable="30"
OrderNumber="" />
<RecordType RecordType="PR" UnitsAvailable="4" QtyAvailable="40"
OrderNumber="" />
</ShipWeek>
</Item>
</Identification>
</Availability_V1>

Here is what I want to do:

Within each ItemIDNo loop


While Shipweek <= Current Week
If RecordType = AA cumulate the value for Qty as AAQTY

If RecordType = BA cumulate the value for Qty as BRQTY

If RecordType = PR cumulate the value for Qty as PRQTY

Wend


Map AAQTY to GeneralAvailabilityQty (found in dest. doc)

Map  BRQTY to BlanketQty (found in dest. doc)

Map  PRQTY to PurchaserReserveQty (found in dest. doc)

I can calculate the current week, but how can I map the AAQTY and
BRQTY and PRQTY to the dest doc?  I am having difficutly
conceptualizing how to distinguish 3 seperate sums and map them
accordingly.

The relevant section of the destination doc look like this:
...
<Item GeneralAvailabiltiyQty="" BlanketQty="" PurchaserReserveQty = ""
/>
...

Thoughts and advice are appreciated.


Adam





[ Post a follow-up to this message ]



    Re: Cumulative Condtional Functoid  
Jan Eliasen


View Ip Address Report This Message To A Moderator Edit/Delete Message


 
02-08-04 01:43 PM

On 26 Jan 2004 10:45:53 -0800, akarchm01_nospam@yahoo.com (Adam)
wrote:

Can't you have three logical-equals functoid that each has RecordType
as input and then also a constant (AA, BA, PR). Connect the output to
three value mappening functoids and let the value
mappening-second-input be the sum you have counted. Let the output
from the valuemappening functoids be the correct field in the output.

>Here is a sample XML instance
> <Availability_V1>
> <Identification PurchaserIDNumber="1008" UserName="RICKMOLICA"
>FromOrgID="C" DateCreated="20031022">
> <Item ItemIDNo="1199" ItemDescription="x" PurchaserItemIDNo="253510"
>PurchaserItemDescription="0">
> <ShipWeek ShipWeek="200404" StartWeek="200340" HoldWeeks="5">
>  <RecordType RecordType="AA" UnitsAvailable="1" QtyAvailable="10"
>OrderNumber="0" />
>  <RecordType RecordType="BA" UnitsAvailable="2" QtyAvailable="20"
>OrderNumber="" />
>  <RecordType RecordType="PR" UnitsAvailable="3" QtyAvailable="30"
>OrderNumber="" />
>  </ShipWeek>
> <ShipWeek ShipWeek="200404" StartWeek="200352" HoldWeeks="">
>  <RecordType RecordType="AA" UnitsAvailable="1" QtyAvailable="11"
>OrderNumber="" />
>  <RecordType RecordType="BA" UnitsAvailable="2" QtyAvailable="21"
>OrderNumber="" />
>  <RecordType RecordType="PR" UnitsAvailable="3" QtyAvailable="31"
>OrderNumber="" />
>  </ShipWeek>
> <ShipWeek ShipWeek="200406" StartWeek="200401" HoldWeeks="">
>  <RecordType RecordType="AA" UnitsAvailable="1" QtyAvailable="12"
>OrderNumber="" />
>  <RecordType RecordType="BA" UnitsAvailable="2" QtyAvailable="22"
>OrderNumber="" />
>  <RecordType RecordType="PR" UnitsAvailable="3" QtyAvailable="32"
>OrderNumber="" />
>  </ShipWeek>
>  </Item>
> <Item ItemIDNo="2284" ItemDescription="y" PurchaserItemIDNo="0"
>PurchaserItemDescription="Unable to map">
> <ShipWeek ShipWeek="200414" StartWeek="200404" HoldWeeks="5">
>  <RecordType RecordType="AA" UnitsAvailable="2" QtyAvailable="20"
>OrderNumber="0" />
>  <RecordType RecordType="BA" UnitsAvailable="3" QtyAvailable="30"
>OrderNumber="" />
>  <RecordType RecordType="PR" UnitsAvailable="4" QtyAvailable="40"
>OrderNumber="" />
>  </ShipWeek>
>  </Item>
>  </Identification>
>  </Availability_V1>
>
>Here is what I want to do:
>
>Within each ItemIDNo loop
>
>
>While Shipweek <= Current Week
> If RecordType = AA cumulate the value for Qty as AAQTY
>
> If RecordType = BA cumulate the value for Qty as BRQTY
>
> If RecordType = PR cumulate the value for Qty as PRQTY
>
>Wend
>
>
>Map AAQTY to GeneralAvailabilityQty (found in dest. doc)
>
>Map  BRQTY to BlanketQty (found in dest. doc)
>
>Map  PRQTY to PurchaserReserveQty (found in dest. doc)
>
>I can calculate the current week, but how can I map the AAQTY and
>BRQTY and PRQTY to the dest doc?  I am having difficutly
>conceptualizing how to distinguish 3 seperate sums and map them
>accordingly.
>
>The relevant section of the destination doc look like this:
>...
><Item GeneralAvailabiltiyQty="" BlanketQty="" PurchaserReserveQty = ""
>/>
>...
>
>Thoughts and advice are appreciated.
>
>
>Adam

--
Jan Eliasen, representing himself and not the company he works for.
MCP in Microsoft BizTalk Server





[ Post a follow-up to this message ]



    RE: Cumulative Condtional Functoid  
Tan Bao Nguyen


View Ip Address Report This Message To A Moderator Edit/Delete Message


 
03-26-04 07:14 PM

Adam,

Could you include your schemas, map, and an instance input file?

Thanks,
Tan Nguyen
Microsoft BizTalk Server

This posting is provided "AS IS" with no warranties, and confers no rights.

-------------------- 
18:45:53 GMT) 
cpmsftngxa07.phx.gbl!cpmsftngxa06.phx.gbl!TK2MSFTNGP08.phx.gbl!newsfeed00.su
l.t-online.de!t-online.de!newsfeed.icl.net!newsfeed.fjserv.net!news.maxwell.
syr.edu!postnews1.google.com!not-for-mail 






[ Post a follow-up to this message ]



    Sponsored Links  




 





   All times are GMT. The time now is 09:05 PM.      Post New Thread    Post A Reply      
  Last Thread   Next Thread Next


Most Popular forums 

Forum Jump:
Rate This Thread:

Forum Rules:
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
HTML code is OFF
vB code is ON
Smilies are ON
[IMG] code is OFF
 
Medical and Health forum | Computer Games Reviews | Graphics design forum

Back To The Top
Home | Usercp | Faq | Register