cancel
Showing results for 
Search instead for 
Did you mean: 

Values missing in queue context

sahana_ps
Participant
0 Kudos

Hi All,

I have encountered this ERROR many times,but this time I am unable to figure out the reason behind this mapping failure.Below is my source structure image

I am getting ERROR as below

Cannot create target element /ns0:Messages/ns0:Message1/ns2:GLJournalsDataPost[2]/GL_Document/DocumentHeader/LineItem. Values missing in queue context. Target XSD requires a value for this element, but the target-field mapping does not create one. Check whether the XML instance is valid for the source XSD, and whether the target-field mapping fulfils the requirement of the target XSD

Here its not pointing to any particular field value.Many records are there with Header and LineItem details.If i test each record individually in ESR test tab it works but if i test all records at a time it fails with above error.Kindly need your help

Accepted Solutions (1)

Accepted Solutions (1)

praveen_sutra
Active Contributor
0 Kudos

hi Sahana,

The number of entries in target getting created for LineItem is not the same as expected.

Yes its true that on checking on individual level it might not give error.

So you need to check what is the no of Lineitems getting generated with the context for target xml.

There might be not the right elements in each context so Please make sure you put proper context change and no of elements in total queue should be appropriate.

Please share your target structure  and Mapping for better clarity.

Hope this helps.

thanks and regards,

Praveen T

Answers (9)

Answers (9)

Former Member
0 Kudos

Hi,

Not sure if you added manually the first two tags e.g. Messages & Message1 when you pasted the test data for your mapping?

Update:- I think my above question should not be the reason as I saw just now that you are able to see the values in display queue.

Regards,

Sarvesh

sahana_ps
Participant
0 Kudos

It's not for LineItems Field.Its for the root tag

former_member191435
Contributor
0 Kudos

show me the display queue for line items after the collapse context and without collapse context

sahana_ps
Participant
0 Kudos

Tried Collapse Context,no use.still the same error

former_member191435
Contributor
0 Kudos

show me the error are you getting this error in lineitems field or root tag Lineitem error

sahana_ps
Participant
0 Kudos

Hi

Both are same,since context change is added after formatbyExample ,its showing as 59 and 60

former_member191435
Contributor
0 Kudos

can you please explain your scenario...

Do you want to create for one office field value  to one kind of line items and one office field to oke kind of line items..

for one office field you need to create 1 generaldata post...

Try to use collapse context after formatbyexample for line items mapping and let me know...

please let us know

sahana_ps
Participant
0 Kudos
sendhil_kumar
Active Participant
0 Kudos

Hi,

There is one less Line item here. That is throwing error here. Can you please provide one more screenshot showing Line item and Office in source structure?

--

Sendhil

former_member191435
Contributor
0 Kudos

count no of line items and office fields first and let me know.....

as per ur screen shot no of line items 59 and office fields are 60... 

Let me know on which structure this office field.

Thanks,

Sreenivas

former_member191435
Contributor
0 Kudos

please find the difference using collpase context and without collapse context after format by example...

Without collpase context it will crreate the no of line items that exists for first office field..

Withcollpase context it will create only the no of line items that we have the office field values...

Thanks,

Sreenivas

sahana_ps
Participant
0 Kudos

Hi all,

I am still facing same issue.

I checked number of Line Items and Number of Values in Office are same.

I tried adding Map with Default after office field ,still the same issue

former_member191435
Contributor
0 Kudos

can you please show me your display queue....

Meanwhile use sort function to sort the values of office field and do the splitbyvalue change function...

Thanks,

Sreenivas

sendhil_kumar
Active Participant
0 Kudos

Hi Sahana,

The values might be same since, you have used split by Value (ValueChange), there could be two or more consecutive values of Office might be same. That will be the reason for this.

--

Sendhil

sahana_ps
Participant
0 Kudos

My Target structure and mapping to Lineitems  looks like below :

praveen_sutra
Active Contributor
0 Kudos

hi Sahana,

Please check

1)     if  no of elements in office is equal to no of elements of LineItem by doing display  queue.

     both should be same.

2) if target Line elements generated is having same no of context change as the no of Line items to be generated in the target XML.

I know this is little complex  but my suggestion would be put a [splitbyvalue] after formatbyexample that will give you a better understanding.

hope this helps.


thanks and regards,

Praveen T

sendhil_kumar
Active Participant
0 Kudos

Hi Sahana,

The number of Line Items and Number of Values in Office should be the same. If you can see display queue in formatbyExample, you can identlify the difference.

Hope this helps.

---

Sendhil

former_member191435
Contributor
0 Kudos

where is this office field..... in line items where it exactly coming...

Meanwhile you can do one thing...

Use mapwiddefault

Officefield ----> Map wid defalut ----> Remove context

Let me know still if u face an issue...

Thanks,

Sreenivas

Former Member
0 Kudos

Hello Sahana,

I suppose here you are sharing your source structure,can you plz share your target structure as well.

As to just the occurrences.

Regards

Naveen

AlexanderApel
Participant
0 Kudos

Hi,

try Occurrences with 0..1. Then you can see your target message.

Regards,

Alex