ASG
IBM
Zystems
Cressida
Icon
Netflexity
 
  MQSeries.net
Search  Search       Tech Exchange      Education      Certifications      Library      Info Center      SupportPacs      LinkedIn  Search  Search                                                                   FAQ  FAQ   Usergroups  Usergroups
 
Register  ::  Log in Log in to check your private messages
 
RSS Feed - WebSphere MQ Support RSS Feed - Message Broker Support

MQSeries.net Forum Index » WebSphere Message Broker (ACE) Support » MRM TDS Padding problem

Post new topic  Reply to topic
 MRM TDS Padding problem « View previous topic :: View next topic » 
Author Message
Luca81
PostPosted: Wed Jun 13, 2007 10:58 am    Post subject: MRM TDS Padding problem Reply with quote

Acolyte

Joined: 01 Mar 2007
Posts: 62

Hi all.

I have other problem with MRM (TDS) format.
I have to comunicate with AS/400 and i have an XML like input.
I have to map XML on MRM (TDS)
The message is very big (about 30 elements). The elements are all String or Decimal (min occ 1, max occ 1).

First I initialize (like IBM suggests) all elements. The order is the same of the Message Set Definition.

SET OutputRoot.MRM.Message.Element1 = '';
SET OutputRoot.MRM.Message.Element2 = '';
...
....
SET OutputRoot.MRM.Message.Elementx ='';

Second I set the values in a bad order

SET OutputRoot.MRM.Message.Element2 = InputRoot.XML.Message.El1;
SET OutputRoot.MRM.Message.Element3 = InputRoot.XML.Message.El2;
...
...
SET OutputRoot.MRM.Message.Element1 = InputRoot.XML.Message.El3;

I have 3 decimals so defined
Lenght: 2
Justification: Right Justify
Padding Char: '0'
Vertual Decimal Point: 0
Signe Orientation: Leading

So if XML element is, for example, 3 I have 03 like output.
All works fine except with one decimal .
For 2 decimals I have the correct output (xml element with padding).
For one decimal the padding does not work . If i have 3 like input... I have 3 like output and not 03...
The 3 decimals are declared with the same properties.
Could be a set order problem?
Pls help me
Thx a lot
Luca
Back to top
View user's profile Send private message
kimbert
PostPosted: Wed Jun 13, 2007 2:34 pm    Post subject: Reply with quote

Jedi Council

Joined: 29 Jul 2003
Posts: 5542
Location: Southampton

Quote:
The message is very big (about 30 elements)
Either each element is very big, or that's a fairly small message

Quote:
For one decimal the padding does not work . If i have 3 like input... I have 3 like output and not 03...
What is the content of the source element in each case? Are they all the same ESQL type in ( CHARACTER / DECIMAL/... )?

Quote:
Could be a set order problem?
I doubt it.

- Double check that the properties are the same on all 3 elements ( check in the mxsd file to be certain )
- Take a user trace of the parse, and look for warnings about self-defining elements ( I'm assuming that you are on v6 ).
Back to top
View user's profile Send private message
Luca81
PostPosted: Wed Jun 13, 2007 9:43 pm    Post subject: Reply with quote

Acolyte

Joined: 01 Mar 2007
Posts: 62

[quote="kimbert"]
Quote:
Either each element is very big, or that's a fairly small message




Quote:
What is the content of the source element in each case? Are they all the same ESQL type in ( CHARACTER / DECIMAL/... )?

All have the same content... DECIMAL.

Quote:

- Double check that the properties are the same on all 3 elements ( check in the mxsd file to be certain )


Done 4 times

Quote:
- Take a user trace of the parse, and look for warnings about self-defining elements ( I'm assuming that you are on v6 ).

I don t have warning . And I m on version 5.0 CSD 10

The exactly istruction is
SET refOut.GGCalcdataValMovCash = COALESCE(refCashFlow.*:OtherMovSpotDays,'00');

If I correct with
SET refOut.GGCalcdataValMovCash = RIGHT('0'||COALESCE(refCashFlow.*:OtherMovSpotDays,'00'),2);

All work fine. But this is not good... WBI should padding my string



Pls help me
thx
Luca
Back to top
View user's profile Send private message
kimbert
PostPosted: Thu Jun 14, 2007 12:39 am    Post subject: Reply with quote

Jedi Council

Joined: 29 Jul 2003
Posts: 5542
Location: Southampton

Quote:
I don t have warning
You won't get those warnings unless you are on v6. You can still check for self-defining elements, though. Just enable validation in your message flow, and you will get a validation error if the message tree does not match your message definitions.
Back to top
View user's profile Send private message
Luca81
PostPosted: Thu Jun 14, 2007 1:11 am    Post subject: Reply with quote

Acolyte

Joined: 01 Mar 2007
Posts: 62

kimbert wrote:
Quote:
I don t have warning
You won't get those warnings unless you are on v6. You can still check for self-defining elements, though. Just enable validation in your message flow, and you will get a validation error if the message tree does not match your message definitions.


I enabled validation... But i don't have warning because the message tree matches my message definitions .
This is tha trace

Executing statement 'SET refOut.GGCalcdataValMovCash = COALESCE(refCashFlow.*:OtherMovSpotDays, '00');' at (Ordine.DB_AnaContrReq.Main, 196.3).
Evaluating expression 'COALESCE(refCashFlow.*:OtherMovSpotDays, '00')' at (Ordine.DB_AnaContrReq.Main, 196.3.
Evaluating expression 'refCashFlow.*:OtherMovSpotDays' at (Ordine.DB_AnaContrReq.Main, 196.47).
Assigning value ''2'' to field / variable 'refOut.GGCalcdataValMovCash'.

All is ok... The problem is the padding
thx
Luca
Back to top
View user's profile Send private message
kimbert
PostPosted: Thu Jun 14, 2007 1:54 am    Post subject: Reply with quote

Jedi Council

Joined: 29 Jul 2003
Posts: 5542
Location: Southampton

Are all 3 decimals members of a Fixed Length structure ( i.e. Data Element Separation of parent is 'Fixed Length') ?
Back to top
View user's profile Send private message
Luca81
PostPosted: Thu Jun 14, 2007 2:07 am    Post subject: Reply with quote

Acolyte

Joined: 01 Mar 2007
Posts: 62

kimbert wrote:
Are all 3 decimals members of a Fixed Length structure ( i.e. Data Element Separation of parent is 'Fixed Length') ?


All decimals have the same parent...
The structure is easy... a lot elements with all the same parent...
The parent has 'Fixed Length' for Data Element Separation
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic  Reply to topic Page 1 of 1

MQSeries.net Forum Index » WebSphere Message Broker (ACE) Support » MRM TDS Padding problem
Jump to:  



You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
Protected by Anti-Spam ACP
 
 


Theme by Dustin Baccetti
Powered by phpBB © 2001, 2002 phpBB Group

Copyright © MQSeries.net. All rights reserved.