Skip to Content
0
Former Member
Jul 30, 2009 at 08:04 PM

Mapping Help Needed - Message or Java UDF

12 Views

Hello Gurus,

I have a source structure as below.

Idoc

-group_a (0 to 99999)

-- sub_groupa_1 (0 to 99999)

-


sga1_field_1

-


sga1_field_2

-- sub_groupa_2

-


sga2_field_1

-


sga2_field_2

.

.

-- sub_groupa_n

-


sgan_field_1

-


sgan_field_2

.

.

-group_n

-- sub_groupn_1

-


sgn1_field_1

-


sgn1_field_2

-- sub_groupn_2

-


sgn2_field_1

-


sgn2_field_2

.

.

-- sub_groupn_n

-


sgnn_field_1

-


sgnn_field_2

every group creates an output group (lineitem), that works fine

now my requirement is as below

a particular output field (per output group) = sum (sub_field_2s) wherever sub_field_1s = first occurence of sub_fld_1 of the corresponding group

I tried different things, but could not get the required results.

pls let me know if my explanation is not clear..

Please help..

thanks

KnowledgeQuest.