on 2011 Jun 24 8:36 AM
HI,
i am getting multiple bill related data in single file.. the structure looks like below
Bill_list 1:1
-- Bill_data 1:unbounded
now i want to split the same file into single bills each.
for example say i am getting data for 2 bills in source file.then i want my output to be 2 files like
Bill_list
--Bill_data(1)
and
Bill_list
--Bill_data(2)
I tried using multimapping by changing target(same source file structure) occurance to o:unbound
and mapped
Bill_data-----> Bill_list (o:unbound)
But my file is not getting splitted into 2.. it says 2nd file cant be created.. Can you suggest where i am going wrong.
TIA
Hi,
In your multimapping, keep the occurrence of the target structure as 0..unbounded.
Map Bill_data to the message tab, so that for each Bill_data, 1 message is created.
For the remaining mapping :
Map Bill_list to a constant 1.
Map Bill_data >splitByvalue->Bill_data
Regards
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
>
> Bill_data-----> Bill_list (o:unbound)
>
> But my file is not getting splitted into 2.. it says 2nd file cant be created.. Can you suggest where i am going wrong.
>
Above mapping wrong,just add remove context as suggested by Harish.i t will work
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
you are mapping:
Bill_data-----> Bill_list (o:unbound)
but Bill_data is comming under Bill_list in source so there is contex changes between Bill_data. Please add remove contex in between.
Bill_data-----> Remove Context -
>Bill_list (o:unbound)
and check your target structure as well.
Regards,
Harish
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
it says 2nd file cant be created
where is this messsage displayed?
Can you suggest where i am going wrong
probably your target structure (occurence) needs some change as all the Bill_data tags might be generating within the first Bill_list itself.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
All Bill_data comes under one bill_list tag only..
Bill_data --> Bill_List
raise the context of Bill_data to a level above source Bill_List
Does Bill_data have further sub-elements? If yes then you can map a blank constant to the target Bill_data.
Then map the sub-elements directly (or as per any business logic) to the corresponding elements under target Bill_data. check the result and confirm
User | Count |
---|---|
66 | |
10 | |
10 | |
10 | |
10 | |
8 | |
6 | |
5 | |
4 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.