JSTL  XML import

In my webpage, I want to seperate my content, style and my html/jstl.
I have a JSTL page, a content page which is pure XML, and then my css file.
What is the best way I can import my xml data info my jstl page?
I know you can do it the folllowing way, but seems a bit long winded:
<c:import url="/someFile.xml" var="doc"/>
<x:parse doc="${doc}" var="parsedDoc"/>
<x:out select="$parsedDoc/home/heading"/>
perhaps javabeans? but how

Instead of x:parse you can use x:transform, but you must specify an XSLT file.
Do the transformation of XML with XSLT outside the JSP, then import XML and XSLT file with c:import for each inside the JSP.
Then call x:transform to transform the XML with XSLT.
I don't recommend JavaBeans for this, unless you want to translate XML to Java Objects and vice versa you can use JAXB to do that.
Now there's XTags - but XTags is not fully released so it's not standardized yet and it's too early to use it.
Message was edited by:
appy77

Similar Messages

  • How to count number of xml nodes , with JSTL XML api?

    I am trying to count the number of nodes in the parsed xml by doing this:
    <x:out select="count($doc/Items/Item)"/>
    There are about 50 item nodes in the source xml, but I get the output as 0
    Is this syntax correct?
    I searched every where but couldn't find the xpath syntax to be used inside jstl xml tags, I was assuming that it's the same as the syntax used in xslt

    Thank you for your reply, sorry I wasnt very clear with my question.
    I want to count the number of nodes inside the jsp file , not inside the xslt file.
    My xml file is something like this for example:
    <?xml version="1.0" encoding="UTF-8"?>
    <DocumentRootNode>
    <Products>
    <Item>1</Item>
    <Item>2</Item>
    <Item>3</Item>
    <Products>
    </DocumentRootNode>
    I want the count of number of Item nodes , in the JSP file.
    I'm doing something like this in the JSP but it gives 0 instead of 3:
    <c:import url="source.xml" var="xml" charEncoding="UTF-8"/>
    <x:parse doc="${xml}" var="xml_doc"/>
    <x:out select="count($xml_doc/Products/Item)"/>
    null

  • Working sample of JSTL:xml?

    Can someone send me a working sample war file using jstl:xml under JSTL 1.1/tomcat 5?
    I think my JSP is right, but I tried it on tomcat-5.5.4, 5.0.28 with JDK1.4.2, JDK1.5.0. All of them give me [#document: null] result. There must be something wrong in my configuration.
    If someone can send me a working war file, I would really appreciate.
    My email address: [email protected]
    Thanks!

    Okay, it is clear to me, you are thinking something that may be working is not, because you are testing incorrectly.
    Doing a c:out of the variable returned from <xml:parse> and getting [#document:  null] is not a sign that the xml document wasn't parsed. I am not sure exatly what the null part of the output means but...
    Look at this code:
    //Sidebar.xml
    <?xml version="1.0"?>
    <home_bar>
        <bar_width>250</bar_width>
        <button_height>30</button_height>
        <button_width>200</button_width>
        <button_img>images/norm_button.gif</button_img>
        <button_list>
          <button id="1">
            <link_url>./</link_url>
            <text>Home</text>
          </button>
          <button id="2">
            <link_url>/Calendar</link_url>
            <text>Calendar</text>
          </button>
          <button id="3">
            <link_url>/Calendar/howto.jsp</link_url>
            <text>How To Use the Calendar</text>
          </button>
          <button id="4">
            <link_url>/Webmail</link_url>
            <text>Webmail</text>
          </button>
          <button id="5">
            <link_url>/Webmail/howto.jsp</link_url>
            <text>Webmail HowTo</text>
          </button>
          <button id="6">
            <link_url>/Web/howto.jsp</link_url>
            <text>How To Make a Web Page</text>
          </button>
          <button id="7">
            <link_url>/HTML/howto.jsp</link_url>
            <text>Learn HTML</text>
          </button>
          <button id="8">
            <link_url>/JS/howto.jsp</link_url>
            <text>Learn JavaScript</text>
          </button>
        </button_list>
    </home_bar>
    //Sidebar.jsp
    <%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
    <%@ taglib prefix="x" uri="http://java.sun.com/jsp/jstl/xml" %>
      <c:import var="sideBarXml" url="Sidebar.xml" />
      <x:parse doc="${sideBarXml}" var="sideBar" />
      <%-- Show that the side bar was read --%>
        <!-- Side Bar = <c:out value="${sideBar}"/> -->
      <%-- End of Test Output --%>
      <x:set var="theBar" select="$sideBar/home_bar"/>
      <style type="text/css">
        .sidebar
          width  : <x:out select="$theBar/bar_width"/>px;
          float  : left;
          clear  : left;
        .button
          background : transparent url(<x:out select="$theBar/button_img"/>) no-repeat scroll center;
          height     : <x:out select="$theBar/button_height"/>px;
          width      : <x:out select="$theBar/button_width"/>px;
          cursor     : pointer;
          float      : left;
          clear      : left;
          text-align : center;
          color      : white;
      </style>
      <div class="sidebar">
         <x:forEach select="$theBar/button_list/button" var="button" varStatus="status">
           <div class="button" onclick="document.location='<x:out select="$button/link_url"/>';">
             <x:out select="$button/text"/>
           </div>
         </x:forEach>
      </div>
    //index.jsp
    <html>
      <head>
        <title>Showing JSTL:XML tags</title>
        <style type="text/css">
          DIV.content
            disaplay: block;
            float   : left;
            clear   : right;
            width   : 500px;
            font-family: Serif;
        </style>
      </head>
      <body>
        <jsp:include page="Sidebar.jsp"/>
        <div class="content">
          Just some things to show for the content of the JSP...
        </div>
      </body>
    </html>
    //WEB-INF/web.xml
    <?xml version="1.0" encoding="ISO-8859-1"?>
    <web-app xmlns="http://java.sun.com/xml/ns/j2ee"
        xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
        xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee web-app_2_4.xsd"
        version="2.4">
      <display-name>XML Display Application</display-name>
    </web-app>
    //HTML Output
    <html>
      <head>
        <title>Showing JSTL:XML tags</title>
        <style type="text/css">
          DIV.content
            disaplay: block;
            float   : left;
            clear   : right;
            width   : 500px;
            font-family: Serif;
        </style>
      </head>
      <body>
        <!-- Side Bar = [#document: null] -->
      <style type="text/css">
        .sidebar
          width  : 250px;
          float  : left;
          clear  : left;
        .button
          background : transparent url(images/norm_button.gif) no-repeat scroll center;
          height     : 30px;
          width      : 200px;
          cursor     : pointer;
          float      : left;
          clear      : left;
          text-align : center;
          color      : white;
      </style>
      <div class="sidebar">
         <div class="button" onclick="document.location='./';">
             Home</div>
         <div class="button" onclick="document.location='/Calendar';">
             Calendar</div>
         <div class="button" onclick="document.location='/Calendar/howto.jsp';">
             How To Use the Calendar</div>
         <div class="button" onclick="document.location='/Webmail';">
             Webmail</div>
         <div class="button" onclick="document.location='/Webmail/howto.jsp';">
             Webmail HowTo</div>
         <div class="button" onclick="document.location='/Web/howto.jsp';">
             How To Make a Web Page</div>
         <div class="button" onclick="document.location='/HTML/howto.jsp';">
             Learn HTML</div>
         <div class="button" onclick="document.location='/JS/howto.jsp';">
             Learn JavaScript</div>
         </div><div class="content">
          Just some things to show for the content of the JSP...
        </div>
      </body>
    </html>The WEB-INF/lib directory contains jstl.jar and standard.jar (JSTL 1.1.1 I think). Nothing but basic Tomcat 5.0.29 installed in the common directories. JDK1.4 installed.
    Anyway, from the output, you can see in the comment inside the HTML source that the c:out for the parsed XML file reads [#document: null]. However, the XML was correctly parsed and generated the proper sidebar.
    I know that if you do something like this:
    <x:set var="theBar" select="$sideBar/home_bar"/>
    <c:out value="${theBar}"/> you get [[home_bar: null]].
    Also, if you do:
    <x:out select="$sideBar"/> you will get all the data from the xml file (not the tags) printed out.

  • JSTL XML problem

    I use Tomcat 5.5.4, Jarkata JSTL 1.1.2, here is what I do:
    (1) copy JSTL jar (standard.jar, jstl.jar) to tomcat common/lib directory
    (2) create a jsp page like:
    <%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
    <%@ taglib prefix="x" uri="http://java.sun.com/jsp/jstl/xml" %>
    <c:import var="data" url="sample.xml" />
    <x:parse var="res" doc="${data}" />
    if I print ${data}, it is correct XML file as I expected. But I always get [document:null] as XML parsing result.
    Besides, whatever JSTL XML function I try, seems all of them give me error or null result.
    Is there any special setting that I miss?
    Why JSTL:core works and JSTL:xml doesn't?
    Anyone have suggestion? Thanks!

    To answer your questions from the previous post: No, I don't have Xalan.jar anywhere, unless it is packaged inside of some other jar, like one of the commons jars.
    I am using Tomcat 5.0.29 or real close to it. Java 1.4.2.
    A further question:
    Do I really need copy c.tld and x.tld to WEB-INF/ and
    set them up in WEB-INF/web.xml?
    No. The tlds inside the JARs are all you need. I would get rid of these copies.
    My understanding is: since you specify that uri:
    http://java.sun.com/jsp/jstl/core, there is no need
    to copy and set-up tld.
    At least, if I remove them, JSTL:core works fine. As
    for JSTL:xml, it doesn't work either way.What version of the web descriptor are you using? Version 2.3 or 2.4? It should either be defined is a <?DOCTYPE... ?> tag (v 2.3) or in the <web-app ...> tag (v. 2.4). You should be using the vs. 2.4.
    I don't know if that would make a difference though...

  • Problem in using request parameters in jstl xml code

    hi,
    my need is to get a request parameter and use the variable in jstl(xml) select conditions.
    my code is ,
    <%String txname=request.getParameter("tname");%>
    <x:forEach var="fe" select="$doc/transaction/tx[@tname=${txname}]/field">
         <field>ss <x:out select="$fe/@fname"/> </field>
    </x:forEach>
    i'm using tomcat5.0. I deployed the jstl.jar, standard.jar, jaxen.jar and saxpath.jar in WEB-INF/lib directory.
    I able to run other jstl(xml) files which doesn't need any variables from out side.
    i used the scirpt for getparameter as i unable to get the code ${param.tname}
    help me.
    urs
    pavan.

    Looks like you haven't imported the taglib:
    JSTL1.0: <%@ taglib prefix="c" uri="http://java.sun.com/jstl/core" %>
    JSTL1.1: <%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
    You use JSTL1.0 in JSP1.2 containers (eg Tomcat 4)
    You use JSTL1.1 in JSP2.0 containers (eg Tomcat 5)
    also check this post if you have further troubles. It has basic troubleshooting for JSTL.

  • JSP/JSTL & XML

    I am trying to have JSP pages parse and read an XML file and then return some data in an HTML table. I'm using the JSTL libraries and have a basic understanding of them, but I apparently need help.
    My first page just gets the value and passes it to the second page. The second page handles all of the processing. Here is my JSP page:
    <%@page contentType="text/html" %>
    <%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
    <%@ taglib prefix="x" uri="http://java.sun.com/jsp/jstl/xml" %>
    <%@include file="index.jsp" %>
    <% String clientID = request.getParameter("enteredID"); %>
    <c:import url="npiXMLTest5.xml" var="doc" />
    <x:parse varDom="dom" doc="${doc}"/>
    <x:set var="srcCID" select="string($dom/npiNumbers/client/clientNum)" />
    <html><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
    <title>NPI XJTL Test</title></head>
    <body>
    <c:set var="CID" value="<%= clientID %>" />
    <h2>NPI XJTL Test Page</h2>
    <table border="1">
    <tr><th>NPI Number</th><th>Description</th></tr>
    <c:choose>
    <c:when test="${CID}=${srcCID}">
    <x:forEach select="$dom/npiNumbers/client/npiNum" var="$n">
    <tr><td><x:out select="$n/npi" /></td><td><x:out select="$n/desc" /></td></tr>
    </x:forEach>
    </c:when>
    <c:otherwise>
    There is an error with your coding
    </c:otherwise>
    </c:choose>
    </table></body></html>My XML structure is as follows:
    <npiNumbers xsi:schemaLocation="http://localhost/namespace NPI_XSD5.xsd" xmlns="http://localhost/namespace" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
    <client>
    <clientNum/>
    <clientName/>
    <npiNum>
    <npi/>
    <desc/>
    </npiNum>
    </client>
    </npiNumbers>I am trying to return the results of the <npiNum> element (which can have multiple values) - <npi> and <desc> - in a table based on the <clientNum> element. I try to evaluate the page variable with the xml element. If it matches, I will return a table. A client can have multiple <npiNum> elements, so the construction of the table is in the x:forEach loop.
    I think my problem is getting the variable from JSP to compare against the <clientNum> element in the XML file.
    Any ideas?

    I think your problem is less JSP/JSTL and more querying the XML.
    You are trying to "select all <npinum> elements from a client based on clientnum"
    I am far from an expert on XPath, but I think the following query is what you are after: "/npinumbers/client[clientNum=????]/npiNum"
    To do that with JSTL you would replace ???? with $param:enteredId or $CID (equivalent in your example)
    Here is the resulting JSP page.
    <%@page contentType="text/html" %>
    <%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
    <%@ taglib prefix="x" uri="http://java.sun.com/jsp/jstl/xml" %>
    <c:import url="npiXMLTest5.xml" var="doc" />
    <x:parse varDom="dom" doc="${doc}"/>
    <html><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
    <title>NPI XJTL Test</title></head>
    <body>
    <c:set var="CID" value="${param.enteredId}" />
    <h2>NPI XJTL Test Page</h2>
    <table border="1">
    <tr><th>NPI Number</th><th>Description</th></tr>
    <x:forEach select="$dom/npiNumbers/client[clientNum=$CID]/npiNum" var="n">
      <tr><td><x:out select="npi" /></td><td><x:out select="desc" /></td></tr>
    </x:forEach>
    </table>
    <hr>
    <form>
    <input type="text" name="enteredId"/>
    <input type="submit">
    </form>
    </body></html>I made up the following test file to use with it. I don't know if it was exactly what your requirements are, but it was a best guess based on your info.
    <npiNumbers>
         <client>
              <clientNum>42</clientNum>
              <clientName>Ford Prefect</clientName>
              <npiNum>
                   <npi>123</npi>
                   <desc>life</desc>
              </npiNum>
              <npiNum>
                   <npi>234</npi>
                   <desc>universe</desc>
              </npiNum>
              <npiNum>
                   <npi>456</npi>
                   <desc>everything</desc>
              </npiNum>          
         </client>
         <client>
              <clientNum>666</clientNum>
              <clientName>Satan</clientName>
              <npiNum>
                   <npi>333</npi>
                   <desc>Baby Devil</desc>
              </npiNum>
         </client>
    </npiNumbers>Cheers,
    evnafets

  • Insane XML Import, Huge Project, Duplicate file names work around...

    I planned on kicking off my journey attempting to edit a massive multi year documentary on FCPX with a nice introduction of the blog I'm going to keep about the experience, but I've run into a bit of a roadblock, or maybe major speed bump at least before even getting to that point. I wanted to share what is working as a work around for me and you guys can tell me how I'm doing it wrong.
    Ok, I will try to explain this as succinctly as possible. I'll write in somewhat stream of consciousness just to try and get through it quicker... Basically, after discovering the work around below, I am now utterly confused on how FCPX handles the relationship between its own database of where media is stored, and the actual media itself. I have plenty experience on FCPX now, probably done 30-40 pro commercial jobs on it over the last year since XML became doable as I'm also a Resolve Colorist and all the FCPX projects where hardcore coloring product spots. For commercial work, I never needed to worry about splitting up footage up over multiple Events. Everything, all in one, FCPX handled it no problem. (well the occasional beach ball, but that seems to be a thing with FCPX in general)
    This will be my 10th feature documentary as an Editor. Every one before it was either on Avid's many flavors over the last 12 years or FCP Studio. When this new film came along, I made the decision a few months ago to use FCPX for a few reasons, but mostly because I'm insane and I like to try to mix it up for myself in a career that can get stale quick if you aren't willing to be that way. The film was shot over 2+ years, every shoot was multi cam 5D (yes i know, looks great, but please kill me), I haven't done the math on length, but there is over 10,000 clips of video (this is actually medium in size compared to what I've dealt with before). Its 5D, so theres external audio for everything. FCPX's syncing is great, but I've learned that theres an unsaid window of heads and tales clips must fall within to sync properly with the nearby clips, if they are too far apart FCPX gives up. One shoot day could have 3 cams, 50 clips each, and 2 audio files to sync to, FCPX simply cannot handle this, so off to Plural eyes they went, no problems.
    Ok, all this is relevant eventually I swear! Again, in the past, all in one event, no problem. I tried for fun to bring all media into one Event on this film. It worked, but there is a 10+ second spinning beach ball for every single move you make, so thats no good. Ok, I'll separate the Events out to, lets say, each shoot month. Well that's dumb, in verite documentary, any shot could be the first, any shot could be the last, you need a command over all searchable footage at all times. Shift selecting all events to search *****, and it actually takes longer for FCP to reload each event each time than it does to just have the one massive one. So no go there. Next hair brained idea... What if make a new Event that is just Compound Clips of all the other Event's contents and do more with Markers and Favorites in logging that I was planning to parse it all out. That way I'm working with and FCPX is dealing with 50-60 clips instead of 10,000+ Quick test, Cmd-A, Opt-G, boom, boom, boom, move all to dedicated to Event, hide huge Event, BEHOLD, that works! FCPX chokes a little bit on the insane length of some of the clips, but searching, and general performance is back on par!
    So your saying to yourself "Ok *********, sounds like you figured it out, what's the problem." Well to you I say, "Not so fast!" Remember, that was just a quick test using the media I had imported into the massive 10,000+ clip Event. To do this project proper, I am having to import Multicam sync'd XMLs from Plural Eyes. And this is where it all starts to fall apart. A little foreshadowing for your eager eyes. 10,000+ files all shot with multiple 5D's over the course of years. What does that mean? many, many duplicate file names!
    FCPX as well all know irritatingly imports XML's as new Events, not into existing ones. This obviously takes a lot of burden off media management because with a new Event comes a new database referencing its own version of the raw media. All well and good, and I'm betting its starting to click for some if you advanced users where I'm finally going with this. So I have 50 or so XMLs to bring in, all done no problem. Now I want to replicate that singular Event like I did with the Compound Clip test and have it all in one place to be my master as extensive logging begins for easy searching once editing begins. Highlight the Events, click Merge Events. NOPE. I get a new "Kill Yourself Now" error (a term I coined for Out of Memory and General Error messages in FCP Legacy meaning there ain't much you can do about it): "Two or more files have the same name. Change the names and try again, because I don't know what the **** to do with them." Ok I made up that last part but that's basically what it's saying. Just take the variable out of the equation, this happens with every which way you could try to get the clips together. Merge Events, dragging events on top of each other, dragging just the Multicam clip alone, nothing gets passed that message. What's worse is that while Batch Renaming seems like a solution, the renames do not populate inside the created clips and there is no way to Batch Rename those. Renaming everything at the finder level isn't so great because then I'd have to resync and theres an offline/online thing going here where the film has to be reconformed eventually.
    Basically, I've found that FCPX handles media management in completely different ways depending on whether you are importing into one Event yourself or doing essentially what is a new import with FCPX moving or merging Events. If you bring in all the media to one Event, on a macro level FCPX goes through file by file making aliases referencing the master file. If it hits a duplicate, it makes a parenthesis counter, and keeps going. And with the genius of FCPX metadata, that file name doesn't even matter, you can change it at the Finder level and FCPX will keep the link intact. BUT for some reason if you try to do this outside the realm of a single Event and combine files after the fact a different process takes over in creating this database system and can't handle the duplicates. I can't totally figure the reason other than it probably is scared to change the originally referenced alias to something else (which it shouldn't be scared of since Merge Events deletes the original anyway).
    This is where it gets INSANE and where I lose all understanding of what is going on, and believe me it was a delicate understanding to begin with. It comes in to play with the work around I figured out. I make the master Event with the 10,000+ clips. Then I import all the XMLs as dedicated Events. Now, I then drag the Multicam clips into the master Event, it WORKS! just takes it, no "Kill Yourself Now" error. Stranger still, now with the switched referenced Event, it even takes into account which aliased duplicate file name it's referencing in the Original Media folder. Somehow, it's taking into account the original file path and saying "Ok, I see 5 instances of MVI_5834.mov. Based on the original file path or maybe creation date or god knows what, it must be MVI_5834 (fcp3).mov." It connects perfectly. I can even remove the old XML imported Event with no problem. Crazier yet, I can now move those again to the dedicated Event I wanted originally that only contains those Multicam or Compound Clips.
    So instead of going straight from A to C, going from A to B to C works even though that actually seems way more complicated. Why can't FCPX handle Merge Events and dragging clips the same way it handles media imported into a single Event. And weirder still, why can't FCPX handle the (fcp1,2,3...) appending in the same scenario. But if the appended links are already there, No Problem. And for the love of god, it'd be nice to important XML's into existing Events and make the correct referencing happen right from the get go, which is really the source of all the above headache. I'd have no problem helping FCPX with a little manual pointing in the right direction just like any other NLE needs.
    Ok, having said all of that crap above, my question is, have I missed something completely simple I should have done instead? Now that I have everything in place how I originally envisioned, I think I will still play around a little bit more to make sure FCPX is really going to be able to handle this project. I'm at a stage right now where going another direction is still an option, although the dare devil in me wants to make this work. Media management aside, once you start editing on a FCPX timeline, its hard to go back to anything else. Apple is going to have to figure out some way not to access to everything at all times to work fluidly or big projects like this are never going to be practical in FCPX.
    Sorry for the long confusing post....

    I'm having the exact same problem, but I know nothing of ruby scripts. I've exhausted my resources with tech support, and after literally hours of work with them it seems I now am faced with either re-rating each individual song, or pointing iTunes to each song that it can't locate. Is yours a solution that could help me? How can I find out more about Ruby Scripts? Thanks for your help, hellolylo (or anyone else who might also be able to help...)
    Kenn

  • Error messages during XML import of Project Pro 2010 files

    Hi folks,
    I'm trying to diagnose a couple of sick Project Pro 2010 files loaded from Project Server by saving them locally as XML files and then reimporting (not connected to the server during import).  The anomalous behavior exhibited by both files
    is that one takes 15 minutes to load from the server, while another takes over 20 minutes. These are not typical load times for this server.  In both cases, Project consumes about 25% of the CPU during the load process. There's little network I/O
    while this goes on, and when externally linked schedules are loaded to the cache, they load very quickly.  Other than the long load times, the schedules appear to be behave normally, except for some very odd print preview behaviors in one of the schedules
    that I asked about in a different thread (among other things, the default print preview start date is 17 years after the default finish date, and the finish date is about 11 years before the schedule actually starts).
    The questions I'm asking here are about errors I see when I try to import the files exported as XML, and whether they might provide any clues as to what's causing the load time issues.
    When attempting to import one of the files saved as XML, a pop-up appears that says, "The actual finish date is before some of the previously entered timephased actual work values. If  you continue with this operation, Project will truncate
    some of the previously entered timephased actual work values. To continue, click OK..."
    When attempting to import the other file saved as XML, I get a series of pop-ups identifying a series of tasks that say, "The timephased edit will cause 'Develop Requirements Review Meeting Mi...' to start before 'Conduct Requirements Review"
    finishes.  As a result the task link cannot be honored.  You can: () Continue. Keep the timephased edit and ignore the link.  () Cancel. Ignore the timephased edit.  (OK/Cancel/Help)".
    Interestingly, both files contain external Project Server predecessor / successor links.  In the case of the first file, the XML import just appears to strip those out.  In the case of the second file, I get a long series of pop-ups (with
    some buggy text inserts) in pairs.  The first message in the pair is typically "An import error occurred.  The element <PredecessorLink> in the <Task> element with <UID>=611 has invalid data.  Verify that the file
    name and path are correct, and then try again. (OK)", where the indicated UID varies. The second pop-up in the pair appears to have a buggy text constructor and looks like this, with "[stet]" indicating the apparent buggy text inserts,
    "An import error occurred.  The element [stet] Verify that the file name and path are correct, and then try again. [stet] in the 309 element with <UID>=7 has invalid data. [stet] ^4 (OK)"
    In the second pop-up of the pair, the "xyz element" varies, but the "<UID>=7" reference and "^4"  are consistent. In the XML, UID 7 appears to refer to a calendar, a task which includes a number
    of entries similar to:
    <TimephasedData>
    <Type>24</Type>
    <UID>7</UID>
    <Start>2014-10-03T08:00:00</Start>
    <Finish>2014-10-04T08:00:00</Finish>
    <Unit>2</Unit>
    <Value>PT8H0M0S</Value>
    </TimephasedData>
    ... and to an assignment:
    <Assignment>
    <UID>7</UID>
    <TaskUID>10</TaskUID>
    <ResourceUID>-65535</ResourceUID>
    <PercentWorkComplete>100</PercentWorkComplete>
    which includes blocks like:
    <TimephasedData>
    <Type>2</Type>
    <UID>7</UID>
    <Start>2014-10-17T08:00:00</Start>
    <Finish>2014-10-17T17:00:00</Finish>
    <Unit>2</Unit>
    <Value>PT8H0M0S</Value>
    </TimephasedData>
    Eventually, the second file also does load with no external file links indicated.
    Again, I'm just looking for anything that might be a clue to the long Project Server load times.
    Thanks in advance,
    LP

    Slow performance can come from a number of different things. Without knowing more detailed information about your setup or workflow, it's difficult to accurately troubleshoot.
    -What kind of Mac are you using?
    -What is your source format?
    -Where is your source footage located?

  • XML import only creates one record at a time

    Hi All,
    I have an XML import map that automatically imports data into main product table. It's working fine when the XML file has only one main record. When it has more than one record, the import manager and import server can only import the last record in the file and skip the rest.
    I already checked the record matching tab. It correctly shows that all records will be created and 0 will be skipped. Even the log file indicates all records are created after I execute the map. Yet, when I try to look for them in the data manager, I can only find the last one. If I execute the map with the exact same file again, it will create one more record again and skip the rest.
    Someone else posted the same question a while back: Import map issue one record at a time. But it was never answered. Does anyone else have this issue? Is this a MDM bug?
    Thanks,
    Kenny

    Hi Kenny,
    Please refer to the note below:
    Note 1575981
    Regards,
    Neethu Joy

  • XML import - stopped due to "critical error"

    Hi all. For the moment, I'm still working with FCS1/FCP 5.1.4, OS 10.4.11.
    In the past, when I've needed to open a project I've started on other machines running 6.0.x, I've done an XML export, and imported said xml file into a new project on my machine. If I recall correctly, XML type 2 worked just fine.
    Well, it doesn't work now, and I'm wondering why?
    The machine I'm exporting from is running OS10.4.11, and FCP 6.0.3. I've exported the project out of there in all flavors of xml (1,2,3 and 4), with and without clip metadata. And I get nothing on import, bupkus, nada, zilch and zero...except for the oh-so-helpful message "XML import stopped due to critical error"
    So who broke this?

    I've had this happen to me when the original project contained sequences that used filters not supported by 5.1.4.
    My solution was to strip out suspect filters until it worked.
    Best,
    Tom

  • Getting img tags to work in sub page using jstl core import tag

    Am trying to bring disparate system page reports together under one web app. This means using the jstl core import tag (I dont want to redirect as I want to hide the urls, this web app provides better security than those it calls).
    Use of the import tag works to a degree but any resources (ie. img tags) don't load.
    Have created a much simplified example that demonstrates..
    So heres the jsp...
    <%@ taglib prefix="c" uri="http://java.sun.com/jstl/core" %>
    <h3>Delivery Performance Report</h3>
    <c:url value="http://localhost/mycontext/subpage.html" var="myUrl"/>
    <c:import url="${myUrl}" />and a simple sub page (note plain html, no jsp, this mimics my project as the other systems are hidden source, non jsp)
    <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2 Final//EN">
    <HTML>
    <HEAD>
    <TITLE>sub page</TITLE>
    </HEAD>
    <BODY>
         This is the sub page<br>
         <img src="images/banner_image.jpg" />
    </BODY>
    </HTML>While I dont get any errors what I do get is ..
    Delivery Performance Report
    This is the sub page
    ...but image fails to load.
    If I redirect instead of import it works, but as I said I need to hide the url from the user as security is an issue.
    Any help appreciated, really pulling my hair out with this final stage of something that will make a real difference to us!
    regards,
    G.

    Thanks for the answer but Im afraid thicko here doesnt get it.
    The img src is relative to the sub page, and I have tried it with an absolute address (ie. http://localhost/.....) with the same result.
    If I call the sub page direct (get with browser) the image tag works. Its just if the sub page is imported with the jstl core import tag.
    I've not tried a base tag. The real project always returns pages containing absolute urls... http://ourReportServer/reports?....plenty of params so dont belive relevant, please correct me if Im wrong here though.
    thanks, G.

  • [CS2][AS] Make XML import map is calling a refresh on styles?

    If this can be of use to someone else... it's probably not CS2,AS specific.. but this is what i use.
    It's the second time i have a bug like this, where changing the order of my calls is fixing the problem. With this one, i was getting random missing font error (times(1)) while batching documents(wich make the batch script batch crash as there is a modal dialog open). Not always on the same document, it was really fustrating as i was not able to get my finger on the problem!
    I actually knew the source of the problem as i had added a fix (maybe not the best solution, but it was working well) that actually was removing the style from all the text frame (i noticed that using map style to tag was not always working well(when text frame had overriden?), so that's why i added code to reset the style before doing a map. But i was not understanding why it was happening so randomly...
    I tought at first it was happening during save (as it reopen the document) but after a few experimentation it looked like it was occuring during the import map redefinition (See code below: make XML import map with properties {markup tag:tStyle, mapped style:tStyle}).
    Looks like the make XML import is calling some sort of document refresh wich then pop the font missing dialog (even with never interact as script preferences!)! (missing font is actually a bug i had also in other circumstances.. exemple when you have a extra return at the end of a tagged text (outside the tag)). A bit unexpected, i really tought that creating a xml import map was just creating data structure in document model to be used later on by the auto style call...
    The problematic script:
    tell application "Adobe InDesign CS2"
    set myDocument to document 1
    tell myDocument
    --Reset styles.
    set applied character style of every text of every text frame of every spread to character style 1
    set applied paragraph style of every text of every text frame of every spread to paragraph style 1
    --Create a tag to style mapping.
    set tList to name of every XML tag
    set tNumItems to count of tList
    repeat with i from 1 to tNumItems
    set tStyle to item i of tList
    make XML import map with properties {markup tag:tStyle, mapped style:tStyle}
    end repeat
    --Map the XML tags to the defined styles.
    auto style
    end tell
    end tell
    And the working solution (just moved the reset of style after the import map creation loop):
    tell application "Adobe InDesign CS2"
    set myDocument to document 1
    tell myDocument
    --Create a tag to style mapping.
    set tList to name of every XML tag
    set tNumItems to count of tList
    repeat with i from 1 to tNumItems
    set tStyle to item i of tList
    make XML import map with properties {markup tag:tStyle, mapped style:tStyle}
    end repeat
    --Reset styles.
    set applied character style of every text of every text frame of every spread to character style 1
    set applied paragraph style of every text of every text frame of every spread to paragraph style 1
    --Map the XML tags to the defined styles.
    auto style
    end tell
    end tell

    it doesnt print any server control message. in my "page_404.jsp" I am printing current date and time (to check if the server visited that page) everytime when i refresh "index.jsp" the server goes to "page_404.jsp" and prints the current date and time.
    so basically the only message which the console shows is the current date/time which i am printing in the "page_404.jsp"
    Thanks.

  • Layout Problem in XML Import

    Dear All,
    I am new in InDesign. I have some problem. I am using InDesign CS3. I want when XML file will be import layout should be come according to our specification with image. Is it possible any script or XSLT. If yes please give me some guiduence.
    I have done XML to Tagged Text using XSLT. But i want to go through XML Import options.
    Anyone please help me...
    Thanks and Regards,
    Byomokesh

    If possible, purchase a copy of A Designer's Guide to Adobe InDesign and XML: Harness the Power of XML to Automate your Print and Web Workflows.
    This book will answer most questions you might have about using XML with InDesign.
    For a short answer, you need to first create styles, then map them to the tags, then import the XML. I will send you an example via email (the author emailed me directly).
    Best regards,
    Tad

  • InDesign CS3 Scripting XML Import Multiple Images into same Text Frame

    I am having trouble importing multiple images into the same Text Frame using XML import. I imported 5 images into the text frame. However, all 5 images are laying on top of one another. Does anyone know if there is a way to have all images laying out like how Microsoft Word handles inline images, i.e., laying out next image to the right of previsous image in the same line and if there is not enough space left in the line, then wrap to next line. Thanks in advance. I understand I could use JavaScript to do post import processing, e.g, calculate the image size and place each images accordingly. But I am trying to see whether there is a way to do this without scripts.

    You can apply an object style to all anchored images by script. A text frame containing main flow should be selected.
    var doc = app.activeDocument;
    var textFrame =  app.selection[0];
    var rectangles = textFrame.texts[0].rectangles;
    if (rectangles.length > 0) {
         for (var i=0; i < rectangles.length; i++) {
              rectangles[i].appliedObjectStyle = doc.objectStyles.item("Cover");
    However, there is a better approach:
    Step 1
    Create place holders for a single "Book" element and format it as needed -- apply an object style to the cover.
    Step 2
    Import the xml file -- the placeholders are replaced with data from the 1st xml element
    Step 3
    Drag & drop the element containing all "Books" elements into the main flow -- all elements are placed and formatted the same way as in step 1.
    Finally, add a new page, click the overset text icon and autoflow text to add pages so that to fit all the text.
    Hope this helps.
    Kasyan

  • Using XML Import/Export in Transport Connection

    Hi, I was investigating the feasibility of copying a query definition from one BW system to another using the XML Import/Export functionality in Transport Connection.  This is not to replace our current transport process across the landscape (Dev -> QA -> Prod), but merely just looking at possibilities for end users who develop queries in QA & then recreate them in Prod.
    My question is: has anyone worked with the XML Export/Import for types Queries & Query Elements?  I was trying this out between a Dev and Sandbox system and only had limited success.  I was able to take a small query and perform the Export to a local .xml file without much difficulty.  But when I try to do the Import, my query never shows up.  The Import function shows a green light, but I get a couple of error messages on the Import such as the following:
    ==========================================================
    SAP object 3WROG4HZ3NKP1PIYHCR1H24CQ () cannot be imported
    Diagnosis
    You attempted to import SAP object 3WROG4HZ3NKP1PIYHCR1H24CQ of type into the system via the XMI interface. However, you are not allowed to import SAP objects.
    System response
    The object was ignored during the import.
    Note: It can be that the import is incomplete when the required SAP objects are still not active in the system.
    Procedure
    Install the specified objects from Business Content. Only import the metadata afterwards.
    =========================================================
    The portion returned for Saving and Activating returns green lights.  The two sample objects mentioned appear to just be custom InfoObjects used in my query & don't look to be any different than others that work OK. 
    Just curious if anyone else has worked with this and could help advise. 
    Thanks...  Jody

    This is an old subject, but I think XML import only works for datamodeling objects like InfoObjects, InfoCubes, and ODS objects. If you try to export a query, and open the XML file in a text editor, there is not enough information (in my opinion) to build the query. As an example you don't see how key figures are to be displayed, filter or free characteristics.
    However, when an InfoObject is collected, you get all the attributes, texts in all languages.
    If anyone has more insight, please enlighten us.
    -John

Maybe you are looking for

  • Can you help me to solve this problem?

    i run this dcl in command window: alter table t storage (freelists 3) ; then oracle tell moe this error : ORA-10620: Operation not allowed on this segment but as i know ,the database version which is above 9i can support this dcl. my database version

  • Integration of SAP MI 7.1 and SAP PI 7.1 on the same Server

    Hi dear SAP Community, Does anyone know, if it's possible to use MI 7.1 and PI 7.1 on one server to create a big Enterprise Service Bus? Thank you! Best Regards Philipp

  • Problems with SCM server 10g and Forms Developer 6i&9i

    Hi, I installed SCM server 10g and try to use it with Forms developer 6i and 9i. The connection to the server works ok but when I choose the container from Source Control Options to check in forms they always go one level higher in the container hier

  • Contents in XMLParser for PL/SQL

    How do you get the contents between tags in a XML document? example: <ejb name="My bean"> <maximum-pool-size>20</maximum-pool-size> </ejb> I want the "20"-value. How do your extract this from a node in a DOM tree? thanx.

  • Free Workflow tutorials for FCS 3

    Want to share these free workflow tutorials for Final Cut Studio 3 (FCP7 & Motion 4, Color & FCP, Motion & DVDSP, STP & FCP). Might be of interest to those who have not yet upgraded. http://www.nedwebserver.com/ned-web/finalcutstudioproworkflows&popu