Flatten to xml from variant

I have problems with flattening variant data to xml-strings. I tried to make an application to save variant data to xml-files, but the vi "flatten to xml" didn't solve always the same solution. The bug don't occur always and i tried alot to show it. The vi produce sometimes not finished xml-strings. I attached a vi, witch shows the bug on my computer every time.
Thanks for help, Mathis Wieland
Attachments:
error_variant_to_string.vi ‏40 KB

I installed OpenG toolbox and OpenG Flatten to XML, the error with changing results is fixed, but this vi can't make variants to a xml-string, as well it has problems with the value fo refnums.
Yours sincerely
Mathis Wieland
Attachments:
error_flatten_to_xml.vi ‏35 KB

Similar Messages

  • Flatten to/Unflatten from XML on ARM

    Using LV 9 with the ARM module on an EK-LM3S8962.
    I want to use XML on the embedded target. The data to be converted is a group of arrays in a cluster. The cluster is a type def in the embedded project. The Flatten to/Unflatten from XML VIs from the ARM pallet are used to convert the cluster to XML and back. This works OK on a Windows deployment but the application build for the ARM deployment fails with this message:
     Status: Error
    linking...
    .\Obj\LabVIEW.axf: Error: L6218E: Undefined symbol FXPLoad32 (referred from ccgxmlsupport.o).
    Target not created 
    I suspect this has something to do with the schema. Does a copy of the schema (LVXMLSchema.xsd) need to be included in the build specifications? If so, how does one add this to the project?
    Thanx
    JohnCS

    Added a fixed point calculation as suggested and now the VI builds and runs OK. 
    So far  so good, but the String to XML primitive does not generate the correct XML string. In my cluster containing two arrays of strings, none of the control labels have been encoded and the array dimensions are encoded as zero. As a consequence, the XML string will not be decoded back to the cluster correctly. In the Windows environment, the same control encodes the labels and dimension sizes.
    Is there something wrong  with my type def'ed control or with the Flatten to XML primitive as well?
    Here's a copy of my project including the build specification but without the built file.
    Attachments:
    xmltest.zip ‏19 KB

  • Error while posting XML from a scheduled transaction to another transaction

    When I try posting an XML from one transaction to another in a different project by calling it as a webservice, it doen't hit the other transaction.
    I see this in the Netweaver error logs:
    java.util.zip.ZipException: error in opening zip file
    at java.util.zip.ZipFile.open(Native Method)
    at java.util.zip.ZipFile.<init>(ZipFile.java:111)
    at java.util.zip.ZipFile.<init>(ZipFile.java:127)  [see details]
    XML AssignXml Parse Error
    [EXCEPTION]
    org.xml.sax.SAXParseException: Premature end of file.... [see details]
    AND
    [Fatal Error] :-1:-1: Premature end of file.
    More interestingly it happens ONLY when I schedule the parent transaction, when I trigger it manual everything works fine.
    Any help appreciated.

    Hi Srinivas,
    I see that this post was marked as answered. Could you please elaborate on how this problem was fixed?
    I am experiencing a similar issue:
    I am trying to get the Active Portal application running in MII 12.1.7 (also 12.1.8) and all went well up to the point where the ActivePortalMonitor transaction is scheduled. In the logs I also receive the  org.xml.sax.SAXParseException.
    The culprit is the XMLQuery block in that txn. Just like with your situation, when ran from workbench it works; when scheduled it doesn't.
    I tried replacing the XMLQuery with other blocks that get the same result, i.e. XMLLoader or HTTPLoader + StringToXMLParser; and in all cases the XML fetching element bombs out.
    I also built a simple txn that does an XMLQuery on another txn and then dumps the output in a file. Same thing: when run from workbench it runs fine; from scheduler it gives "SAX" error
    I would post the specific error log, but it is always varying, here is one example:
    [ERROR] [Untitled_0]org.xml.sax.SAXParseException: Open quote is expected for attribute "DIR" associated with an element type "HTML".
    Any help/hints are much appreciated
    Kind Regards,
    Fanie

  • Flatten to XML does not save Item Names of ListBox to XML file.

    On my Front Panel, I have a ListBox Indicator that has Strings from which the User can select. Also the User can edit items in the ListBox to add new elements. After the user selects one and pushes my Save button, I use the Flatten to XML function to save the selection in an XML file. But Flatten to XML only saves the Value (index of the selected item(s)) to the XML file and not the ListBox Item Names. That is enough information to reconstruct which of the String data that the user selected.
    In a ListBox where a User is selecting among a list of Strings, shouldn't the Flatten to XML function also store the String(s) that were selected?
    Solved!
    Go to Solution.

    Dennis Knutson wrote:
    The control is a U32 which is no different than placing a regular numeric control on the front panel. The flatten to xml is only passed a numeric value in both cases. It can't record something that you do not pass to it. The state of the control is the numeric value and the state can be reconstructed with that numeric. If you want to reconstuct the strings (which are not states), use the property node.
    I disagree. A ListBox that contains Stings to select from is full of String information. Both I and the User entered those Strings into the ListBox. It is the only data in the Listbox that we see. It is the most important information in the ListBox. The Strings are present in the Item Names. The Flatten to XML does have access to the Item Names and can and should provide them. Neither I nor the User are interested in the Numeric Index of the Selected Items. That is useless information to us. Both of use are dealing with Strings. If the State of the ListBox control is to be reconstructed from the XML data provided by the Flatten to XML function, then the Strings (Item Names) in the Listbox must be provided in the XML data.

  • Floating point precision of "Flatten to XML"

    It appears that the "Flatten to XML" function (LV 7.1.1) truncates floating point numbers to 5 decimal places.  This is a rather annoying limitation, since I'm trying to store a relative time in hours, accurate to the second (chosen by a previous coder that I have to be compatible with - otherwise I'd just use seconds).  Is there a workaround to this?  (other than multiplying by some power of 10 before flattening, and dividing after unflattening)
    Jaegen

    Hi Paul and Jaegen,
    I checked our databases and found entries of product suggestions and
    corrective action requests for the behavior of the limited precision
    when flattening to XML. I found an interesting reply from a LabVIEW
    developer on the request for further precision:
    The Flatten To XML primitive puposefully cuts off all numbers at 5
    digits after the decimal. There are 3 main reasons for this:
    Information regarding precision is not propagated on the wire.
    Therefore, there is no real way to know how many significant digits or
    even places past the decimal point is appropriate when data is
    flattened to XML.
    Bloat. If all floating point values printed all of the possible
    decimal digits all of the time, this would provide for some very large
    blocks of XML code.
    Given the arbitrarily complex nature of LabVIEW data, it is
    difficult to provide a method for specifying precision. For example, if
    a user has a cluster of clusters, each of which contain a single,
    double and extended representing various measurements of differing
    accuracy, how can one precision setting be applied to each of these
    values? The user would have to unbundle (and index if an array was
    involved), flatten, concatenate, and then the reverse on the unflatten
    side.
    I suggest that you go ahead and file a new product suggestion by using the "feedback" link on www.ni.com/contact.
    It would be best if you could give some detailed information on how you
    would like LabVIEW to handle different scenarios while getting around
    the above issues.
    Thanks for the feedback!
    - Philip Courtois, Thinkbot Solutions

  • Anyone have example stylesheet for Flatten to XML output

    I would like to log the output of a "flatten to xml" vi and display it in a tabular format in my Teststand xml report.  I'm wondering if anyone has a starting point for the stylesheet side of things.

    Almost there....
    I have a properly formated XML string from Labview to Teststand.  I have the XSL which has been tested and added to my horizontal.xsl used by the Teststand report.  My problem now is that when I log the XML string using Additional Results, Teststand is putting the CDATA tag around the string preventing it from using my XSL.   Is there a flag or something to set so Teststand will add the XML as is.
    I've done this before using the ModifyReportHeader callback and the GetXML method, but the ModifyReportEntry doesn't work for XML reports.  So I really need to know how to stick my XML in the report from my client sequence file without Teststand altering it.
    Thanks,
    Kevin
    Attachments:
    Capture.PNG ‏5 KB

  • Generating an xml from a pl/sql procedure

    Hi Friends,
    I have come up with a requirement to generate an xml from a pl/sql procedure.
    I did some R & D and also got some sample procedures but could not understand the datatypes being used.
    The procedure declares variables like this:
    doc                  xmldom.DOMDocument;
    mainNode         xmldom.DOMNode;
    headerElem      xmldom.DOMElement; Pls could anyone tell what do these xmldom.DOMDocument, xmldom.DOMNode and xmldom.DOMElement mean?
    Later in the procedure, these variables are assigned values like
    doc      := xmldom.newDOMDocument;
    mainNode := xmldom.makenode(doc); This went a bouncer on me.
    Pls help.
    Thanks in advance ...!

    You can check this one -- Learned this from michael.
    satyaki>
    satyaki>
    satyaki>select * from v$version;
    BANNER
    Oracle Database 10g Enterprise Edition Release 10.2.0.1.0 - Prod
    PL/SQL Release 10.2.0.1.0 - Production
    CORE    10.2.0.1.0      Production
    TNS for Linux: Version 10.2.0.1.0 - Production
    NLSRTL Version 10.2.0.1.0 - Production
    satyaki>
    satyaki>
    satyaki>with person_h
      2  as
      3    (
      4      select 1 id, 'M' gender, 'W' race, '170' weight from dual union all
      5      select 1, 'M', 'W', '170' from dual union all
      6      select 1, 'M', 'W', '180' from dual union all
      7      select 1, 'M', NULL, '175' from dual union all
      8      select 1, NULL, 'W', NULL from dual
      9    )
    10    select xmlelement("Person",(
    11                                 select xmlagg(xmlelement("Sex", gender))
    12                                 from (
    13                                        select distinct gender
    14                                        from person_h
    15                                        where id = 1
    16                                        and gender is not null
    17                                      ) pg
    18                                ),
    19                                (
    20                                  select xmlagg(xmlforest(race as "Race"))
    21                                  from (
    22                                         select distinct race
    23                                         from person_h
    24                                         where id = 1
    25                                       ) pg
    26                                ),
    27                                (
    28                                  select xmlagg(xmlforest(weight as "Weight"))
    29                                  from (
    30                                         select distinct weight
    31                                         from person_h
    32                                         where id = 1
    33                                       ) pg
    34                                 )
    35                     ).getstringval() Res
    36    from dual;
    RES
    <Person><Sex>M</Sex><Race>W</Race><Weight>170</Weight><Weight>175</Weight><Weight>180</Weight></Person>
    satyaki>Regards.
    Satyaki De.

  • Get the values from Variants

    I am missing the values from variants..does have anybody have an idea how to retrieve the values of variants..?
    Is it stored some where in SAP..?in any table..?
    Any help would be appreciated.
    Thanks,
    Frank

    Are you having variant problems after an upgrade? If so, you can run:
    RSVARDOC                       Rescue obsolete variants
    or
    RSVARDOC_610                   Rescue obsolete variants
    Depending on your version.
    Rob

  • How to generate XML from EBusiness suite ARXSGPO

    Could someone tell me how I can generate XML from the EBusiness Suite Accounts Receivable report ARXSGPO.rdf I understand this report is called by a C program. I have tried changing the concurrent request to output format to XML the result does not resemble XML. Does anyone have any suggestions how I can generate XML from the ARXSGPO report?
    Thanks,
    Mark

    Hi Mark
    the next release of XMLP will have last page only support. The problem is that at the template layer you do not know how many lines are going to fit on the page, so you never know what is going to be the last page. The only way around it for now is to specify the number of lines to a page and then check when all the lines have been rendered and then render the remit portion.
    I have a sample invoice that does the same, drop me a mail, you can work out the email from my name and the fact I work for XMLP Im sure.
    Tim

  • How to generate XML from SQL query

    possible ways to generate XML from SQL qury.
    i want to generate XML of following query. "Select * from emp,dep wher emp.deptno=dept.deptno"

    Hello.
    Can you try:
    SQL> set pages 0
    SQL> set linesize 150
    SQL> set long 9999999
    SQL> set head off
    SQL> select dbms_xmlgen.getxml('Select * from emp,dep wher emp.deptno=dept.deptno') from dual;
    It works fine for me.
    Octavio

  • Can I copy XML from one RDL file to another

    Hi
    I have created one report, worked on it as a prototype for a project - added datasets , params etc
    I now want to start again - from a template that we have just created - with professional layout, images etc - but want to copy the datasets, parameters from the original prototype to a new report (created from the template).
    Can I just copy sections of the XML from the original RDL file to the new one ?- like the Datasets and parameters sections 
    Regards
    Greg

    Hi,
    Yes, you can.
    If you copy less or more then need you'll see an error.

  • Not able to create XML from an existing relational database

    Hi,
    I am trying to create and xml from an existing relational database. I am not able to get any XML data, I receive "XMLTYPE()" as the result.
    Here's the query -
    SQL> select o.order_id, XMLELEMENT("order", XMLATTRIBUTES(o.order_id as ID)) AS "result" from order_
    info o where order_id=2793;
    ORDER_ID
    result()
    +2793+
    XMLTYPE()
    I was expecting to get +<order id=2793 />+ instead of XMLTYPE().
    I am using -
    SQLPlus: Release 9.0.1.0.1*
    Oracle Database 10g Enterprise Edition Release 10.2.0.1.0 - 64bit Production
    I have also run some checks to confirm XML DB installation -
    SQL> select 1 from all_users where username  = 'XDB';
    +1+
    +1+
    SQL> desc RESOURCE_VIEW;
    Name                                      Null?    Type
    RES                                                SYS.XMLTYPE
    ANY_PATH                                           VARCHAR2(4000)
    RESID                                              RAW(16)
    I think, I have something wrong with installation or configuration.
    Any idea about what have I done wrong here?

    Works fine now. Got the result "<order ID="2793"></order>".
    Thanks. :-)

  • Is there any way to prevent web.xml from any change ?

    hi all,
    we have a filter in web.xml. Now we want to prevent it from any change in future. I mean after making a war(EAR) no one can change the filter in web.xml. if he chaged it then he will not be able to re deploy the application.Right now it is in web.xml so one can easily change it and then he can redeploy the application.
    Is there any way to prevent web.xml from any change after making EAR(WAR)?
    One can easily make a change in web.xml and redeploy the application to get the result. Now we want to restrict the web.xml as java class for any change after making EAR(or WAR).
    Could some one help me to do this?
    thanks,
    dinesh

    I think you could use some third party software to lock the folder like FolderLock, just make sure others ppl cannot access your file should be fined.
    This is my stupid solution only,cheers.

  • Is there any way to prevent web.xml from any change like java class?

    hi all,
    Is there any way to prevent web.xml from any change after making EAR(WAR)?
    One can easily make a change in web.xml and redeploy the application to get the result. Now we want to restrict the web.xml as java class for any change after making EAR(or WAR).
    Could some one help me to do this?
    thanks,
    dinesh

    hi,
    Not at development level. We want it after deploying the application on server .
    We want to create it (web.xml) at tomcat startup (or in any other web/app server ) before loading any context.
    Is there any way to run a simple java class(not servlet) on tomcat startup(before initializing the contexts)?
    Message was edited by:
    DP_java
    Message was edited by:
    DP_java

  • IS IT POSSIBLE 2 BUILD A NEW XML FROM DAMAGED ITL? SAVE FERRIS

    OK. Here's my situation. I have an HP notebook running on VISTA. ITUNES version 8.1.1....... My computer shut off abruptly while I was running ITUNES and after I restarted it and started up Itunes, I got the damaged ITL message. No big deal, I still have all my songs in their designated folder and I'll just import the XML to get all my playlists back in action. I've done this at least 10 times already. Works like a charm everytime. Oh S#!T,... my XML was wiped out during the shut down. I have a program that can retrieve files after recycle bin deletion and the XML is no where to be found. SOOOOOO here's my questiion. When my computer S#!Ted in my cereal, it split my ITL into two seperate damged ITL's. One 32 MB and the other 14 MB. I know the XML is just a backup of the ITL and I frequently update my XML twice a week to make sure no B.S. could bestow it's bad self all up in my shizz. I just never figured to make a copy of the XML because everytime this has happened, the good XML was always there to use. (NOW I KNOW)Soooo, I need to know how to build an new XML from the two damaged itl's. That way I can just import the two new xml's and then save, thus making itunes create a new fresh XML from my two provided and restoring my itunes to it's original self. My problem is I can't get ITUNES to read my two damaged ITL's. Yes, I've done the name change method, no love. I tried the restart computer at a previous date and time method, didn't work. I tried the previous libraries folder and it's five moths old, which is a 10,000 song difference for me. So that way is useless. I even downloaded the same version of ITUNES that I run onto my home computer, which runs on XP, so I could try the system cache method. No love there either. I've stumbled upon a page where a person stated that they were able to manually poke around with their ITL file and forcing ITUNES to repair it. However this person was a computer whiz and I am sooooo totally not. So I had no idea what he was talking about. Anyone dealt with this scenario before? I tried praying to GOD but all he said was "THAT'S WHAT YOU GET FOR PUTTING SHANIA TWAIN'S ..THAT DON'T IMPRESS ME MUCH.. ON YOUR IPOD YOU F%#KING DORK!!!" and I was like, "dude, it is undeniably impossible to not have a smile on your face for the duration of that righteous classic. Then he just f@rted into his hand and released it an inch away from my nostrils, followed by some bird flippage and nut sack grab. So I'm gonna need some help with this one. Thanks Ahead

    How to Transfer Everything from an Old iPad to New iPad
    http://osxdaily.com/2012/03/16/transfer-old-ipad-to-new-ipad/
    iOS: Transferring information from your current iPhone, iPad, or iPod touch to a new device
    http://support.apple.com/kb/HT2109
    Moving Content to a New iPad
    http://tinyurl.com/qzk2a26
    How to Transfer App Data and Game Saves from One iOS Device to Another
    http://lifehacker.com/5891964/can-i-transfer-app-data-and-game-saves-from-my-iph one-to-a-new-ipad
    How to transfer data from your old iPad to your new iPad
    http://www.imore.com/how-transfer-data-your-old-ipad-your-new-ipad-air-or-retina -ipad-mini
    Transferring your prepaid cellular data account depends on your carrier. AT&T lets you move it yourself when you go to Cellular Data in Settings and log into your account with your previous AT&T user name and password. For iPads with Sprint service, you can set up an account on the new iPad and contact Sprint Customer Care (888-211-4727 and go through the menus) to deactivate the old plan and get credit for unused service. For Verizon, call the company’s customer service number for mobile broadband support (800-786-8419) and ask to have your account transferred.
     Cheers, Tom

Maybe you are looking for