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 » tds writing problem

Post new topic  Reply to topic
 tds writing problem « View previous topic :: View next topic » 
Author Message
mrgate
PostPosted: Mon Apr 21, 2008 1:54 pm    Post subject: tds writing problem Reply with quote

Centurion

Joined: 28 Feb 2007
Posts: 141
Location: India

Hello All,
I am working on an integration where source is sap and target is tds format.
I have to map from source from source to target.

Target structure looks like this.

Root(1..N)
AREF(1)
AENV(1)
A010(1..N)
. A015(1..N)
. A025(1..N)
. A020(1..N)
. A030(1)
. A035(1..N)
. A040(0..N)
PO10(1..N)
. PO15(0..N)
. PO25(1..N)
S010(1)

Each element AREF,AENV...etc will have elements of fixed length and at start of element will have respective indicators like AREF,AENV... etc.

Here root is having 1 to n cardinality and AREF is having single cardinality.

when I have created message set for this structure,

I have created complex types to AREF,AENV,A010....etc. All of them are having "data element separation" property as fixed length and group indicators as AREF,AENV,A010.... etc and group terminator as <LF>.

for parent complex types, for A010,A015,A020,PO10,Root, I have given "data element separation" as tagged fixed length where length of tag is set to 4.

the structure designed is working fine when correct lengths are specified.

when the lengths are reduced by more than 1 character it is throwing exception(normal and expected output).

when the lengths are reduced by 1 character it is not throwing any exception and taking line feed as a character(which is not an expected output).
_________________
MQSeries terrorist
Back to top
View user's profile Send private message
mrgate
PostPosted: Mon Apr 21, 2008 2:06 pm    Post subject: Reply with quote

Centurion

Joined: 28 Feb 2007
Posts: 141
Location: India

I am sorry to post second time as the structure is not posted properly.

Root(1..N)
..................AREF(1)
..................AENV(1)
..................A010(1..N)
.................................. A015(1..N)
...................................................A025(1..N)
..................................A020(1..N)
...................................................A030(1)
...................................................A035(1..N)
...................................................A040(0..N)
..................PO10(1..N)
...................................PO15(0..N)
...................................................PO25(1..N)
..................S010(1)


under root structure comes AREF,AENV,A010,PO10,S010.
under A010 comes A015, A020.
under po10 comes P015.

In the same way structure comes out
_________________
MQSeries terrorist
Back to top
View user's profile Send private message
kimbert
PostPosted: Tue Apr 22, 2008 2:41 am    Post subject: Reply with quote

Jedi Council

Joined: 29 Jul 2003
Posts: 5542
Location: Southampton

Quote:
the structure is not posted properly
Code:
use \[code\] tags
 if
  you
   want
    indentation
     preserved


Quote:
when the lengths are reduced by 1 character it is not throwing any exception and taking line feed as a character
Your message consists of fixed-length records separated by line-feeds. Your message definition contains fixed-length structures only. You have not told the parser anything about line feeds. The parser is therefore behaving exactly as you have instructed it.

I suggest:
- Represent each record type with a complex type with Data Element Separation set to 'Variable Length Elements Delimited'
- Set the length of all fields in the complex type apart from the final field
- Set the Group Terminator to '<LF>' ( or whatever combination of line feed chars you require ).
- Create an element from each complex type and set its tag to the record identifier.
- Create a top-level message definition which uses Tagged Fixed Length. Set the Tag Length to 4. Add a reference to each of the record elements.

This will ensure that the line feeds cannot be interpreted as part of the data. However, the final field of each record is now variable-length.
If you want the length of the final field to be checked, you should
- Put a 'Length' Value Constraint on its simple type
- Enable validation in the message flow
Back to top
View user's profile Send private message
mrgate
PostPosted: Tue Apr 22, 2008 6:02 am    Post subject: Reply with quote

Centurion

Joined: 28 Feb 2007
Posts: 141
Location: India

kimbert wrote:

Represent each record type with a complex type with Data Element Separation set to 'Variable Length Elements Delimited'


Hello Kimbert,
when we are setting complex type's Data Element Separation to 'Variable Length Elements Delimited' we are prompted for entering the delimiter in the delimiter field.

our test data looks like this:

Code:

AREFmvicf90042                         01  177667227                          01 
AENV200802202024000001105CF 1105     8440001     1005000001
A01020080220      20080220                008051AMKBWL                                   20080220PM002292900  1105         1                                                 
A012DBMcK MCKESSON DRUG WILSONVILLE                         
A01511PM0022929           Y                   
A012SU                                                       
A0159290042               Y                   
P010STCASCADE HEALTHCARE-BEND            2500 NE NEFF ROAD                  BEND                               OR97701    40162509                                                                                             P01511AS6610693           Y                   
P020000001000001                                                                                 0000003              EA                                   0055.80                                         7332618181          20080212                                                                                   000081.60000000083                                                 
P025N450419018802         Y                   
S010000000001000000081.60                   


length of each segment is too long so thats why data came in new line for A010,P010,P015,P020 segments but the entire data for segment comes in one single straight line.
_________________
MQSeries terrorist
Back to top
View user's profile Send private message
mrgate
PostPosted: Tue Apr 22, 2008 6:05 am    Post subject: Reply with quote

Centurion

Joined: 28 Feb 2007
Posts: 141
Location: India

Hello Kimbert,
From our data, we can clearly see that there is no delimiter between fields of each segment. can we get any suggestion.
_________________
MQSeries terrorist
Back to top
View user's profile Send private message
jefflowrey
PostPosted: Tue Apr 22, 2008 7:25 am    Post subject: Reply with quote

Grand Poobah

Joined: 16 Oct 2002
Posts: 19981

Please follow the second suggestion kimbert made, as well as the remaining ones, in addition to the first one of changing to variable length elements delimited.
_________________
I am *not* the model of the modern major general.
Back to top
View user's profile Send private message
Bartez75
PostPosted: Fri Apr 25, 2008 4:25 am    Post subject: Reply with quote

Voyager

Joined: 26 Oct 2006
Posts: 80
Location: Poland, Wroclaw

Hi mrgate.
Have you been able to solve it? How you did it?
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 » tds writing 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.