Author |
Message
|
mbprimer |
Posted: Wed Apr 04, 2007 9:23 am Post subject: Delimited symol takes precedence than length attribute |
|
|
Novice
Joined: 25 Mar 2007 Posts: 21
|
Hi,
I am using TDS Format with '@' as delimited for each field.i.e
field1@field2@field3@--- for example in my msg set i mentioned the field2 lenht as '0'. If i give my i/p data as
aa@bbbbb@ccc@--- .The field2 is populated with 'bbbbb'. eventhouth its length is zero.
Is Delimited symbol @ takes the precedence than the Length attribute in TDS?
Thanks... |
|
Back to top |
|
 |
elvis_gn |
Posted: Wed Apr 04, 2007 10:41 am Post subject: Re: Delimited symol takes precedence than length attribute |
|
|
 Padawan
Joined: 08 Oct 2004 Posts: 1905 Location: Dubai
|
Hi mbprimer,
mbprimer wrote: |
Is Delimited symbol @ takes the precedence than the Length attribute in TDS? |
I think it does DEPENDING on which TDS format you are using....maybe you should play around with the "Tagged Fixed length" or "Variable Length elements delimited" and see if that works for you...
Regards. |
|
Back to top |
|
 |
mbprimer |
Posted: Wed Apr 04, 2007 11:42 am Post subject: Delimited symol takes precedence than length attribute |
|
|
Novice
Joined: 25 Mar 2007 Posts: 21
|
I am using 'All elements delimited" Format.Probably this gives the precedence to the Delimiter @ than length attribute in my case.
Thanks elvis.. |
|
Back to top |
|
 |
vk |
Posted: Wed Apr 04, 2007 3:51 pm Post subject: |
|
|
Partisan
Joined: 20 Sep 2005 Posts: 302 Location: Houston
|
I assume you are working on MB6.
For a type defined as "All Elements Delimited", the length and default value constraints will not be taken into consideration. This is the default behavior.
If you want the length to be taken into consideration, check the property "Observe Element Length" for the type. The padding will happen to make the element length same as what is defined in the message set before the delimiter is assigned between elements.
Regards,
VK. |
|
Back to top |
|
 |
Mensch |
Posted: Wed Apr 04, 2007 6:29 pm Post subject: |
|
|
Disciple
Joined: 17 Jul 2005 Posts: 166
|
Try out using "Variable Length elements delimited" _________________ Thanks and Regards ,
Mensch |
|
Back to top |
|
 |
kimbert |
Posted: Thu Apr 05, 2007 2:18 am Post subject: |
|
|
 Jedi Council
Joined: 29 Jul 2003 Posts: 5542 Location: Southampton
|
Mensch is correct. 'All Elements Delimited' means exactly what is says; all elements are delimited, and the lengths are ignored.
The name 'Variable Length Elements Delimited' has confused a lot of people. It means 'If an element has length=0, then it is delimited. Otherwise the TDS parser will respect the length'. |
|
Back to top |
|
 |
|