JKI Discussion Forums
Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

Can't read XML into a slightly different cluster

#1
User is offline   trobertson 

  • Group: Members
  • Posts: 1
  • Joined: 14-July 08
I was hoping that EasyXML could be used to create a file format which would allow newer versions of our software to read files from older versions and vice versa. This simple test (attached) seems to indicate that is not possible. Is there a way to arm twist it into doing what I want?

Attached File(s)


0 kudos

#2
User is offline   TonP 

  • Group: Members
  • Posts: 104
  • Joined: 28-July 06

View Posttrobertson, on Jul 14 2008, 04:54 PM, said:

I was hoping that EasyXML could be used to create a file format which would allow newer versions of our software to read files from older versions and vice versa. This simple test (attached) seems to indicate that is not possible. Is there a way to arm twist it into doing what I want?

Here's my try, I haven't fully tested it but it should work.

Inspired by OpenG builder, the XControl Init state and this post.

Ton

Attached File(s)


This post has been edited by TonP: 15 July 2008 - 05:48 AM

0 kudos

#3
User is offline   Jim Kring 

  • Group: JKI Team
  • Posts: 1,204
  • Joined: 15-March 06

View Posttrobertson, on Jul 14 2008, 09:54 AM, said:

I was hoping that EasyXML could be used to create a file format which would allow newer versions of our software to read files from older versions and vice versa. This simple test (attached) seems to indicate that is not possible. Is there a way to arm twist it into doing what I want?


Sorry, for the delay in response. We've been distracted by the launch of the VIPM 2.0 public beta :)

You have discovered a bug that appears, off hand, to only affect the Numeric data type. For example: try changing your "new feature" Numeric to any other (non-Numeric) data type and it should work. We'll make a note of it and add it to the known issues.

Also, if you're an EasyXML customer and this is a show-stopper for you, please let us know and we'll try to get you a pre-release of a fixed version.

Thanks,

-Jim
0 kudos

#4
User is offline   Omar Mussa 

  • Group: JKI Team
  • Posts: 88
  • Joined: 12-October 06

View PostJim Kring, on Jul 16 2008, 06:07 AM, said:

We'll make a note of it and add it to the known issues.


This issues has been added to the known issues forum here.
0 kudos

#5
User is offline   waldemar.hersacher 

  • Group: Members
  • Posts: 9
  • Joined: 10-November 09
  • Gender:Male
  • Location:Germany
This is an old thread resulting in an pending known issue. In my opinion there is no error related to Easy XML.
In the original post a XML string is created from a cluster of version 1.0. This string is parsed into a cluster of version 1.0 and then is tried to convert to a cluster of version 1.1 with "Variant to Data". The variant input does not match the type to convert to. See Missing-elements-incorrect.png

The right and correct functional way is to parse with a cluster of version 1.1 and then convert it to LV data. In this case the variant input and the type is matching for "Variant to Data". See Missing-elements-correct.png

Attached thumbnail(s)

  • Attached Image: Missing_elements_incorrect.png

Attached image(s)

  • Attached Image: monthly_11_2009/post-2801-1259185407.png

This post has been edited by waldemar.hersacher: 25 November 2009 - 09:44 PM

0 kudos

#6
User is offline   Jim Kring 

  • Group: JKI Team
  • Posts: 1,204
  • Joined: 15-March 06

View Postwaldemar.hersacher, on Nov 25 2009, 01:43 PM, said:

This is an old thread resulting in an pending known issue. In my opinion there is no error related to Easy XML.
In the original post a XML string is created from a cluster of version 1.0. This string is parsed into a cluster of version 1.0 and then is tried to convert to a cluster of version 1.1 with "Variant to Data". The variant input does not match the type to convert to. See Missing-elements-incorrect.png

The right and correct functional way is to parse with a cluster of version 1.1 and then convert it to LV data. In this case the variant input and the type is matching for "Variant to Data". See Missing-elements-correct.png


Hi Waldemar,

Thanks for posting your great insights on this issue.

I agree with you that it's a good idea to keep a snapshot of every version of your data structure that you need to support, and then define a conversion process migrating versions. In fact, I wrote a blog article called "Supporting Multiple Versions of a File Format" that discusses some similar concepts. :)

Regarding the known issue, it's certainly arguable about whether this should be a "bug" or a "feature". Still, it would be nice if EasyXML made it easier to handle missing elements in the XML. Of course, it would be useful to know when this happens and which elements were missing. For example, we could add a Boolean argument called "Allow Missing XML Elements? (False)" that allows the more flexible behavior. We could also output some data that tells which elements were missing (for users who care to know). We're not totally decided about how to handle this, but we're certainly thinking about it. After all, making EasyXML more flexible, makes the programmer's job easier -- and, "easy" is what EasyXML is all about ;)

Thanks,
0 kudos

Share this topic:


Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic