Problem using JRC 2.0 on Unix with xml data source

Hello,
I am experimenting difficulties using the JRC 2.0 (which I hadn't with the previous version) on a RedHat 4 machine. It takes 7 minutes (only 20 seconds on Windows) to create a pdf (1 page) from a simple report using an xml file as data source.
It takes approximately 2 minutes when opening the report
      > reportClientDoc.open(REPORT_NAME, 0);
then 4 minutes are required to connect the report to the xml data source
      > reportClientDoc.getDatabaseController().setDataSource(xml_ds, "", "");
Have you got any clue on possible reasons for this issue ?
Edited by: florian epiard on Jan 30, 2009 4:33 PM

Hello,
I am experimenting difficulties using the JRC 2.0 (which I hadn't with the previous version) on a RedHat 4 machine. It takes 7 minutes (only 20 seconds on Windows) to create a pdf (1 page) from a simple report using an xml file as data source.
It takes approximately 2 minutes when opening the report
      > reportClientDoc.open(REPORT_NAME, 0);
then 4 minutes are required to connect the report to the xml data source
      > reportClientDoc.getDatabaseController().setDataSource(xml_ds, "", "");
Have you got any clue on possible reasons for this issue ?
Edited by: florian epiard on Jan 30, 2009 4:33 PM

Similar Messages

  • XmlDataProvider .... is gone completely in my Xaml file. Why? How many different ways to deal with xml data source through WPF

    I followed a procedure described in a book.
    1. insert "Inventory.xml" file to a project "WpfXmlDataBinding" .
    2. add the XML data source through the data panel of "blend for 2013", named it "InventoryXmlDataStore" and store it in the current document.
    3. dragged and droppped the nodes from the Data panel onto the artboard.
    Then I checked my Xaml file against the one provided by the book
    Xaml file by the book:
    <Window.Resources>
    <!-- This part is missing in my xaml file --><XmlDataProvider x:Key="InventoryDataSource"
    Source="\Inventory.xml"
    d:IsDataSource="True"/>
    <!-- This part is missing in my xaml file -->
    <DataTemplate x:Key="ProductTemplate">
    <StackPanel>
    <TextBlock Text="{Binding XPath=@ProductID}"/>
    <TextBlock Text="{Binding XPath=Cost}"/>
    <TextBlock Text="{Binding XPath=Description}"/>
    <CheckBox IsChecked="{Binding XPath=HotItem}"/>
    <TextBlock Text="{Binding XPath=Name}"/>
    </StackPanel>
    </DataTemplate>
    </Window.Resources>
    <Grid>
    <ListBox HorizontalAlignment="Left"
    ItemTemplate="{DynamicResource ProductTemplate}"
    ItemsSource="{Binding XPath=/Inventory/Product}"
    Margin="89,65,0,77" Width="200"/>
    </Grid>
    my Xaml file:
    <Window x:Class="WpfXmlDataBinding.MainWindow"
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    Title="MainWindow" Height="922" Width="874">
    <Window.Resources>
    <DataTemplate x:Key="ProductTemplate">
    <StackPanel>
    <TextBlock Text="{Binding XPath=@ProductID}"/>
    <TextBlock Text="{Binding XPath=Cost}"/>
    <TextBlock Text="{Binding XPath=Description}"/>
    <CheckBox IsChecked="{Binding XPath=HotItem}"/>
    <TextBlock Text="{Binding XPath=Name}"/>
    </StackPanel>
    </DataTemplate>
    </Window.Resources>
    <Grid DataContext="{Binding Source={StaticResource InventoryXmlDataStore}}">
    <ListBox HorizontalAlignment="Left" Height="370"
    ItemTemplate="{DynamicResource ProductTemplate}"
    ItemsSource="{Binding XPath=/Inventory/Product}"
    Margin="65,55,0,0" VerticalAlignment="Top" Width="270"/>     
        </Grid>
    </Window>
    All looks quite the same except the <XmlDataProvider ....> part under <Window.Resources>, which is gone completely in my Xaml file.
    1, Why?
    2, How many different ways to deal with xml data source through WPF?
    Thanks, guys.
    (ps My "WpfXmlDataBinding" runs without problem through.)

    Never do yourself down Richard.
    Leave that to other people.
    It's quite common for smart developers to think they're not as good as they are.
    I coach a fair bit and it's a surprisingly common feeling.
    And to repeat.
    Never use anything ends .. provider.  They're for trivial demo apps.  Transform xml into objects and use them.  Write it back as xml.  Preferably, use a database.
    You want to read a little mvvm theory first.
    http://en.wikipedia.org/wiki/Model_View_ViewModel
    Whatever you do, don't read Josh Smiths explanation.  I used to recommend it but it confuses the heck out newbies. Leave that until later.
    Laurent Bugnion did a great presentation at mix10.  Unfortunately that doesn't seem to be working on the MS site, but I have a copy.  Download and watch:
    http://1drv.ms/1IYxl3z
    I'm writing an article at the moment which is aimed at beginners.
    http://social.technet.microsoft.com/wiki/contents/articles/30564.wpf-uneventful-mvvm.aspx
    The sample is just a collection of techniques really.
    I have a sample which involves no real data but is intended to illustrate some aspects of how viewmodels "do stuff" and how you use datatemplates to generate UI.
    I can't remember if I recommended it previously to you:
    https://gallery.technet.microsoft.com/WPF-Dialler-simulator-d782db17
    And I have working samples which are aimed at illustrating line of business architecture.  This is an incomplete step by step series but I  think more than enough to chew on once you've done the previous stuff.
    http://social.technet.microsoft.com/wiki/contents/articles/28209.wpf-entity-framework-mvvm-walk-through-1.aspx
    The write up for step2 is work in progress.
    https://gallery.technet.microsoft.com/WPF-Entity-Framework-MVVM-78cdc204
    Hope that helps.
    Recent Technet articles: Property List Editing;
    Dynamic XAML

  • MapViewer with XML data source

    Hello all,
    We have the MapViewer read data from JDBC data source doing spatial queries. Can any one tell me if I can use XML data source as input to the MapViewer.
    We have a data source that is only available thru Web services, we cannot make a database view on the schema.
    If not is it planned in the production version.
    Thanks

    How does the xml data look like? in GML?
    If the xml data set is not too large, maybe you can add them (after your application has parsed them) as additional MapViewer GeoFeatures in a map request.
    Currently MapViewer (preview or production release of 9.0.4) does not support xml-only datasource.
    We will look into incorporating GML or other standard-based xml datasource for a future release of MapViewer.

  • CollapsiblePanel with XML data source

    I've been working with the CollapsiblePanel for the past two
    nights. I can't make the panel collapse at runtime when I have XML
    data attached.
    I validated by downloading one of the Adobe Lab
    CollapsiblePanel samples. I validated that I could make the sample
    work from my Dreamweaver CS3 environment. Then, I added an XML data
    source and retested. The panel would not collapse. Then, I took out
    the XML dataset and retested the CollapsiblePanel. It worked.
    Is this a design feature? I can't imagine this was designed
    to work this way. I'm trying to create a scrollable div that can
    collapse. I have everything working except the collapse feature.
    (BTW: I tried defining a spry:region and spry:detailregion, it
    didn't seem to matter.)
    CODE SNIPIT
    <div id="CollapsiblePanel1" class="CollapsiblePanel"
    spry:region="dsWeek">
    <div class="CollapsiblePanelTab">Standard Collapsible
    Panel</div>
    <div class="CollapsiblePanelContent">
    <p>{feature}</p>
    </div>
    </div>

    How does the xml data look like? in GML?
    If the xml data set is not too large, maybe you can add them (after your application has parsed them) as additional MapViewer GeoFeatures in a map request.
    Currently MapViewer (preview or production release of 9.0.4) does not support xml-only datasource.
    We will look into incorporating GML or other standard-based xml datasource for a future release of MapViewer.

  • Create offline interactive forms using webdynpro java with XML data source

    Hi Gurus,
    I am having a scenario like below:
    Sales guy request for order list online from portal- Sytem receives the request and creat XML file- from xml file need to create a Offline interactive form-Sales guy fills it offline at customer site- uploads in portal -on submit xml has to be generated with captured data at customer site-Process to  ECC.
    So my questions are:
    How to create the offline interactive form  from XML?
    Once filled offline interactive form uploaded into portal how to create XML again from pdf ?
    Please give some idea on this as this is my first Offline interactive form using XML datasource.
    Thanks
    Ravi
    Edited by: Ravi Sunkara on Jul 27, 2010 5:25 PM

    Hi Otto,
    Sorry for replying lately. First of all  I did not get your suggestions as your are editing the same posting.
    Secondly we will be using WDJ. Actually in between SAP Portal and ECC we are having adobe LCES so we need to create Interactive form using XML only. Once it is filled again the form will be submitted to another application which is running on FLEX, which will process the order.
    if you can give me your personal id i can send you the detailed process
    Thanks
    Ravi

  • 10g Reports issue with XML Data Source

    Hi,
    Has anybody ever encountered an issue with Oracle 10g report using an XML as the data source? What happens is, some of the values in the XML are printed to the wrong column.
    One of the elements in our XML file is a complex type with 10 elements under it. The first 5 are picked up properly, but the last 6 are not. Elements #6 to #9 has a minimum occurence of 0. What happens is when element #6 is present, but #7 is, the value for element #7 is passed on to element #6.
    The XSD and XSL files are both valid since the reports were working when we were still using 9i. There is no hidden logic in the report which might cause this issue to come up, i.e., the report just picks up the values from the XML and prints it to the appropriate columns.
    Any help will be greatly appreciated.

    XSD used
    <?xml version="1.0" encoding="UTF-8"?>
    <xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" elementFormDefault="qualified">
            <!-- trade instructions detail & trailer -->
            <xs:element name="TradeDetail">
                    <xs:complexType>
                            <xs:sequence>
                                    <xs:element ref="TradeType"/>
                                    <xs:element ref="TradeID"/>
                                    <xs:element ref="TradeDate"/>
                                    <xs:element ref="FundID"/>
                                    <xs:element ref="FundName"/>
                                    <xs:element ref="DollarValue" minOccurs="0"/>
                                    <xs:element ref="UnitValue" minOccurs="0"/>
                                    <xs:element ref="PercentageValue" minOccurs="0"/>
                                    <xs:element ref="OriginalTradeID" minOccurs="0"/>
                                    <xs:element ref="CancellationFlag"/>
                            </xs:sequence>
                    </xs:complexType>
            </xs:element>
            <xs:element name="Instruction">
                    <xs:complexType>
                            <xs:sequence minOccurs="0">
                                    <xs:element ref="TradeDetail" maxOccurs="unbounded"/>
                            </xs:sequence>
                    </xs:complexType>
            </xs:element>
            <!-- overall trade instruction message -->
            <xs:element name="InterchangeHeader">
                    <xs:complexType>
                            <xs:sequence>
                                    <xs:element ref="Instruction"/>
                            </xs:sequence>
                    </xs:complexType>
            </xs:element>
            <!-- definition of simple elements -->
            <xs:element name="FundID" type="xs:string"/>
            <xs:element name="TradeType" type="xs:string"/>
            <xs:element name="TradeID" type="xs:string"/>
            <xs:element name="TradeDate" type="xs:string"/>
            <xs:element name="FundName" type="xs:string"/>
            <xs:element name="DollarValue" type="xs:decimal"/>
            <xs:element name="UnitValue" type="xs:decimal"/>
            <xs:element name="PercentageValue" type="xs:decimal"/>
            <xs:element name="OriginalTradeID" type="xs:string"/>
            <xs:element name="CancellationFlag" type="xs:string"/>
    </xs:schema>
    XML used
    <?xml version = '1.0' encoding = 'UTF-8'?>
    <InterchangeHeader xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="TradeInstruction.xsd">
       <Instruction>
          <TradeDetail>
             <TradeType>Purchase</TradeType>
             <TradeID>M000038290</TradeID>
             <TradeDate>20061201</TradeDate>
             <FundID>ARO0011AU</FundID>
             <FundName>ABN Fund</FundName>
             <DollarValue>2111.53</DollarValue>
             <CancellationFlag>N</CancellationFlag>
          </TradeDetail>
          <TradeDetail>
             <TradeType>Redemption</TradeType>
             <TradeID>M000038292</TradeID>
             <TradeDate>20061201</TradeDate>
             <FundID>ARO0011AU</FundID>
             <FundName>AMRO Equity Fund</FundName>
             <UnitValue>104881.270200</UnitValue>
             <CancellationFlag>N</CancellationFlag>
          </TradeDetail>
          <TradeDetail>
             <TradeType>ISPurchase</TradeType>
             <TradeID>M000038312</TradeID>
             <TradeDate>20061201</TradeDate>
             <FundID>MLC0011AU</FundID>
             <FundName>Cash Fund</FundName>
             <OriginalTradeID>M000038311</OriginalTradeID>
             <CancellationFlag>N</CancellationFlag>
          </TradeDetail>
       </Instruction>
    </InterchangeHeader>
    XSLT used
    <?xml version="1.0" encoding="UTF-8"?>
    <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
            <xsl:output method="xml" version="1.0" encoding="UTF-8" indent="yes"/>
            <xsl:template match="/">
                    <InterchangeHeader>
                            <xsl:for-each select="InterchangeHeader/Instruction/TradeDetail">
                            <xsl:sort select="FundName"/>
                            <xsl:sort select="TradeDate"/>
                                    <TradeDetail>
                                            <TradeType><xsl:value-of select="TradeType"/></TradeType>
                                            <TradeID><xsl:value-of select="TradeID"/></TradeID>
                                            <TradeDate><xsl:value-of select="TradeDate"/></TradeDate>
                                            <FundID><xsl:value-of select="FundID"/></FundID>
                                            <FundName><xsl:value-of select="FundName"/></FundName>
                                            <DollarValue><xsl:value-of select="DollarValue"/></DollarValue>
                                            <UnitValue><xsl:value-of select="UnitValue"/></UnitValue>
                                            <PercentageValue><xsl:value-of select="PercentageValue"/></PercentageValue>
                                            <OriginalTradeID><xsl:value-of select="OriginalTradeID"/></OriginalTradeID>
                                            <CancellationFlag><xsl:value-of select="CancellationFlag"/></CancellationFlag>
                                    </TradeDetail>
                            </xsl:for-each>
                    </InterchangeHeader>
            </xsl:template>
    </xsl:stylesheet>

  • Jasper Report with XML data Source problem

    I have a problem in getting a report run on my machine..
    I have a report that uses XML-dataSource to read info stored in xml file, I use XPath query to traverse xml nodes,
    I have JBoss Server installed but the problem is that I want to know how to configure JBoss and tell it where to look for the xml file so the report can produce right information.
    I use Windows XP and JBoss 4.23 and I finished the report using i-report 2.0.2
    please I need the configuration steps to make this report work... thanx in advance

    Hi,
    Have a look at below URL.
    http://ireport.sourceforge.net/cap7.html#7.4
    Regards
    VInK

  • Problem in filling jasper report with XML Data source

    Hello!
    I am trying to build a report uxing xml data source..Please verify following code:
    String outFileName = "c:/Report1.pdf";
    File xmlFileName = new File("C:/Program Files/JasperSoft/iReport-1.2.5/report.jrxml");
    String recordPath = "/SiteDetails/Site";
    JasperDesign jasperDesign = JRXmlLoader.load(xmlFileName);
    JasperReport jasperReport = JasperCompileManager.compileReport(jasperDesign);
    JRXmlDataSource jrxmlds = new JRXmlDataSource(new File("c:/NewSite.xml"),recordPath);
    HashMap hm = new HashMap();
    try
    JasperPrint print = JasperFillManager.fillReport(jasperReport,hm,jrxmlds);
    JRExporter exporter = new net.sf.jasperreports.engine.export.JRPdfExporter();
    exporter.setParameter(JRExporterParameter.OUTPUT_FILE_NAME,outFileName);
    exporter.setParameter(JRExporterParameter.JASPER_PRINT,print);
    exporter.exportReport();
    catch (JRException jre)
    jre.printStackTrace();
    catch (Exception e)
    e.printStackTrace();
    My Xml file is:
    <?xml version="1.0" encoding="UTF-8"?>
    <SiteDetails>
    <Site>
    <Name>Site1</Name>
    <Addr>Bangalore</Addr>
    <supersiteid>null</supersiteid>
    </Site>
    <Site>
    <Name> Site2</Name>
    <Addr> Madras</Addr>
    <supersiteid>Site1</supersiteid>
    </Site>
    </SiteDetails>
    I want to display details of Siteand Address..My program works fine but displays only 1 (first) record...What should i do to display the full file..do i need to navigate thru the file and give that as an input to fillReport ()method...

    Hi,
    Have a look at below URL.
    http://ireport.sourceforge.net/cap7.html#7.4
    Regards
    VInK

  • Problems using Anyconnect 3.x client together with Kaspersky AntiVirus

    We have Notebooks with Windows Vista - most of the notebooks have "Kaspersky Anti-Virus 6.0 für Windows Workstation" installed and some "Kaspersky Endpoint Security 8 für Windows".
    Anyconnect 2.5 works perfect on these notebooks.
    But when I upgrade anyconnect to version 3.0 or 3.1, I have the problem that all HTTP traffic is blocked - all other network traffic is still working.
    When I quit the Kaspersky client (or uninstall it), everything is working again - except that I have no working antivirus protection.
    Of course, I have tried different settings for the Kaspersky client (without success) and asked our Kaspersky support (who said that anyconnect is causing this problem and not Kaspersky).
    My first experience with a Windows 7 notebook is that this problem does not exist using Windows 7.
    So maybe the problem is caused by a strange combination of Windows Vista, Anyconnect 3.x and Kaspersky.
    Does anyone else has problems using Anyconnect 3.x client together with Kaspersky AntiVirus?
    Kind regards,
    Peter

    We've recently run into an issue related to this. We found that it was related somehow to Firefox. If one looks inside of
    /Applications/Cisco/Cisco AnyConnect Secure Mobility Client.app/Contents/MacOS/ there are symlinks to Firefox libraries:
    $ ls -lntotal 1800-rwxrwxr-x  1 0     80  891232 Aug  3  2012 Cisco AnyConnect Secure Mobility Clientlrwxr-xr-x  1 1001  80      60 Jun 13 15:57 libmozsqlite3.dylib -> /Applications/Firefox.app/Contents/MacOS/libmozsqlite3.dyliblrwxr-xr-x  1 1001  80      55 Jun 13 15:57 libnspr4.dylib -> /Applications/Firefox.app/Contents/MacOS/libnspr4.dyliblrwxr-xr-x  1 1001  80      54 Jun 13 15:57 libnss3.dylib -> /Applications/Firefox.app/Contents/MacOS/libnss3.dyliblrwxr-xr-x  1 1001  80      58 Jun 13 15:57 libnssutil3.dylib -> /Applications/Firefox.app/Contents/MacOS/libnssutil3.dyliblrwxr-xr-x  1 1001  80      54 Jun 13 15:57 libplc4.dylib -> /Applications/Firefox.app/Contents/MacOS/libplc4.dyliblrwxr-xr-x  1 1001  80      55 Jun 13 15:57 libplds4.dylib -> /Applications/Firefox.app/Contents/MacOS/libplds4.dyliblrwxr-xr-x  1 1001  80      58 Jun 13 15:57 libsoftokn3.dylib -> /Applications/Firefox.app/Contents/MacOS/libsoftokn3.dylib
    So as a simple confirmation we were able to remove Firefox and have AnyConnect connect fine. As a more permanent workaround we replaced the above symlinks with 0 byte files and we were able to have our cake (AnyConnect connecting) and eat it too (Firefox installed as well).

  • 64bit CR-Enterprise wont talk with 32bit data source, 32bit IDT wont use 64bit connection for universe. How do I connect them.

    Hi.
    I installed the full suite of tools as I am involved with a company intended to become a partner and reseller so we are trying to get everything working.
    SAP Crystal Server 2013 SP1
    BusinessObjects Business Intelligence platform
    SAP Crystal Reports for Enterprise
    SAP HANA
    SAP Crystal Reports 2013 SP1
    SAP BusinessObjects Explorer
    SAP Crystal Dashboard Design 2013 SP1
    Crystal Server 2013 SP1 Client Tools
    SAP BusinessObjects Live Office 4.1 SP1
    .NET SDK
    I found out that BI was needed only after I installed all the others but I installed it without problem.
    My issue is that the Information Design Tool (IDT) which creates my universes successfully, and even lets me open and see the dada no problem. Is using a 32bit (ODBC connected to SQL Server 2008) data source.
    However, I am unable to load the .UNX in crystal reports (CR) 2011, so I used CR Enterprise (CRE) to connect to my universe. Now when I try to open the universe I start getting the following error:
    [Microsoft][ODBC Driver Manager] The specified DSN contains an architecture mismatch between the Driver and Application
    When I do searches online I get very generic information relating to setting up data sources. While I believe the problem is indeed with the data source, I don't believe it is setup wrong.
    When I access the universe using the IDT (which uses the 32bit version of the data source to build its connection, it wont let me use a 64bit) I can load a table under the "result objects for query #1" press refresh, I get a list of data.
    When I access the same universe using CRE (which "Seems" to use a 64bit data source, but I am not sure), and follow the same process as above. I get the above error.
    If I cancel the process, when CRE lists the fields for the report I can later manually map these fields to an ODBC connection. But if I have to do this what is the point of using the universes at all as the end user has full access to all the various DB's available in the data source.
    Thanks in advance for any help you can provide.

    On the server where Crystal Reports Server is installed, create a 64-bit ODBC connection with the same name as the 32-bit connection.  CRS will then automatically use the 64-bit version of the connection.
    -Dell

  • Is anyone facing the similar problem of visible lag while opening app with 3G data on? It seems apple has made 5s slow to improve iphone 4 performance.5s was very smooth on 7.0.6 even with 3G data on. Is this a bug? Is apple going to fix this soon?

    Is anyone facing the similar problem of visible lag while opening app with 3G data on? It seems apple has made 5s slow to improve iphone 4 performance.5s was very smooth on 7.0.6 even with 3G data on. Is this a bug? Is apple going to fix this soon?

    I have same Problem. I tried all options - Reset All Settings, Erase Content & reset all settings, Upgrated to IOS8.1, Restore using iTune. But problem persists.
    When I turn Cellular Data or Wifi ON, then there is a lag while opening the Apps. But If I turn Data/Wifi off, phone becomes super fast. I have checked with my friends. They are not facing this issue. Not sure if Apple know this.

  • Using ConnBean and CursorBean with a Data Source

    Hi all,
    I',m making a web app. using the Jdev (RUP4) with OA Extension. I looked in the help menu under "About Data-Access JavaBeans and Tags". Here I found the following example, but for some stange reason I cannot get the setProperty to work.
    Example: Using ConnBean and CursorBean with a Data Source This following is a sample JSP page that uses ConnBean with a data source to open a connection, then uses CursorBean to execute a query.
    <%@ page import="java.sql.*, oracle.jsp.dbutil.*" %>
    <jsp:useBean id="cbean" class="oracle.jsp.dbutil.ConnBean" scope="session">
    <jsp:setProperty name="cbean" property="dataSource"
    value="<%=request.getParameter("datasource")%>"/>
    </jsp:useBean>
    <% try {
    cbean.connect();
    String sql="SELECT ename, sal FROM scott.emp ORDER BY ename";
    CursorBean cb = cbean.getCursorBean (CursorBean.PREP_STMT, sql);
    out.println(cb.getResultAsHTMLTable());
    cb.close();
    cbean.close();
    } catch (SQLException e) {
    out.println("<P>" + "There was an error doing the query:");
    out.println("<PRE>" + e + "</PRE>\n<P>"); }
    %>
    Does anyone know how to set the "Property" to a datasource and make it work?
    Best regards,
    MHCI

    There is no point-and-click (Import Data Source Metadata) way to use an LDAP server as a datasource. You have to use the Java Function provided on dev2dev. If you need help with it, please post here.
    - Mike

  • Problem with finding data-source

    I get the following exception: javax.naming.NameNotFoundException: jdbc/localDatabaseDS not found
    when i try to initiate my ds (datasource). Does anybody know what to do?
    class =
    import java.sql.Connection;
    import java.sql.SQLException;
    import javax.sql.DataSource;
    import javax.naming.Context;
    import javax.naming.InitialContext;
    import javax.naming.NamingException;
    import javax.naming.NameNotFoundException;
    * This class handles handles the connectionpool business <br>
    * @author Taeke de Jong
    public class DbConnectionPool {
    private DataSource ds = null;
    * constructor with datasource from JNDI
    public DbConnectionPool(String dataSource)
    try {
    Context context = new InitialContext();
    ds = (DataSource) context.lookup('jdbc/localDatabaseDS');
    catch(NameNotFoundException nox) {System.out.println(nox.toString());}
    catch(NamingException nex) {System.out.println(nex.toString());}
    web.xml =
    <servlet>
    <servlet-name>DbConnectionServlet_2</servlet-name>
    <servlet-class>minlnv.ifw.common.connection.DbConnectionServlet</servlet-class>
    <init-param>
    <param-name>databaseName</param-name>
    <param-value>localDatabase</param-value>
    </init-param>
    <init-param>
    <param-name>dataSource</param-name>
    <param-value>jdbc/localDatabaseDS</param-value>
    </init-param>
    <load-on-startup>2</load-on-startup>
    </servlet>
    <resource-ref>
    <description>JNDI DataSource localDatabase IFW</description>
    <res-ref-name>jdbc/localDatabaseDS</res-ref-name>
    <res-type>javax.sql.Datasource</res-type>
    <res-auth>APPLICATION</res-auth>
    </resource-ref>
    data-sources.xml =
    <data-source class="com.evermind.sql.DriverManagerDataSource"
    connection-driver="oracle.jdbc.driver.OracleDriver"
    ejb-location="jdbc/localDatabaseDS"
    inactivity-timeout="30"
    location="jdbc/localDataseCorDS"
    name="localDatabase"
    pooled-location="jdbc/localDatabasePooledDS"
    url="jdbc:oracle:thin:@10.160.140.30:1521:ifwt"
    // left out password and username
    min-connections="7" max-connections="10" connection-retry-interval="1" xa-location="jdbc/xa/OracleXADS"
    />

    Do not use the "hardcoded" examples from the book. Check the deployed data-sources and use them as parameter calling lookup method.
    The following have been tested using a simple servlet with Jdeveloper 9.0.5.2 but I think other Jdeveloper/OC4J versions work similar.
    My application is called ds.
    The following command lists the datasources which are deployed with the application.
    I ran the following command against the %JDEV_HOME%\j2ee\home standalone OC4J server but it should work against the embedded OC4J server too.
    Here is the command to list the available datasources:
    C:\jdev9052\j2ee\home>\jdk142_04\bin\java -jar admin.jar ormi://localhost admin welcome -application ds -dataSourceInfo
    And here is the output of the command.
    DataSource info:
    com.evermind.sql.DriverManagerXADataSource/ds/jdbc/xa/BookDBXADS - cached: 0 used: 0 total: 0
    com.evermind.sql.OrionPooledDataSource/ds/jdbc/BookDBPooledDS - cached: 0 used: 0 total: 0
    com.evermind.sql.OrionCMTDataSource/ds/jdbc/BookDBDS - cached: 0 used: 0 total: 0
    com.evermind.sql.DriverManagerXADataSource/ds/jdbc/xa/DEVXADS - cached: 0 used: 0 total: 0
    com.evermind.sql.OrionPooledDataSource/ds/jdbc/DEVPooledDS - cached: 1 used: 0 total: 1
    com.evermind.sql.OrionCMTDataSource/ds/jdbc/DEVDS - cached: 1 used: 0 total: 1
    ds = ds my application
    jdbc/DEVDS = string parameter used in lookup method
    jdbc/DEVPooledDS = string parameter used in lookup method
    Checking the j2ee application directory we can find the same:
    C:\>dir C:\jdev9052\j2ee\home\applications\ds\META-INF
    Volume in drive C has no label.
    Volume Serial Number is A83F-C94A
    Directory of C:\jdev9052\j2ee\home\applications\ds\META-INF
    08/12/2004 10:14 AM <DIR> .
    08/12/2004 10:14 AM <DIR> ..
    08/12/2004 10:14 AM 395 application.xml
    08/12/2004 10:14 AM 933 data-sources.xml
    08/12/2004 10:14 AM 283 orion-application.xml
    3 File(s) 1,611 bytes
    2 Dir(s) 10,078,003,200 bytes free
    The orion-application.xml points the data-sources.xml file in the same directory. ds application uses the datasources which are listed in this file, not data-sources.xml in C:\jdev9052\j2ee\home\config directory.
    And here is the content of C:\jdev9052\j2ee\home\applications\ds\META-INF\data-sources.xml
    C:\>more C:\jdev9052\j2ee\home\applications\ds\META-INF\data-sources.xml
    <?xml version = '1.0' encoding = 'windows-1252'?>
    <!DOCTYPE data-sources PUBLIC "Orion data-sources" "http://xmlns.oracle.com/ias/dtds/data-sources.dtd">
    <data-sources>
    <data-source name="jdev-connection-BookDB" class="com.evermind.sql.DriverManagerDataSource" location="jdbc/BookDBCoreDS" x
    a-location="jdbc/xa/BookDBXADS" ejb-location="jdbc/BookDBDS" pooled-location="jdbc/BookDBPooledDS" connection-driver="oracle
    .jdbc.driver.OracleDriver" username="myname" password="mypw" url="jdbc:oracle:thin:@122.118.222.17:1521:DXX" inactivity-timeout
    ="30"/>
    <data-source name="jdev-connection-DEV" class="com.evermind.sql.DriverManagerDataSource" location="jdbc/DEVCoreDS" xa-loca
    tion="jdbc/xa/DEVXADS" ejb-location="jdbc/DEVDS" pooled-location="jdbc/DEVPooledDS" connection-driver="oracle.jdbc.driver.Or
    acleDriver" username="myname" password="mypw" url="jdbc:oracle:thin:@122.118.222.17:1521:DXX" inactivity-timeout="30"/>
    </data-sources>
    ...location="jdbc/DEVDS"
    or
    ...location="jdbc/BookDBPooledDS"
    The lookup method needs the string(s) above (between "")

  • Problem with multiple XML data sources

    Hi there,
    I have a template (i'm using XML publisher). I need to use 2 different XML data files in the same template, but i couldn't find any way of doing so. Can somebody help me with this issue please? You obviously cannot load 2 XML Data sources in the same template.
    Thanks and Regards,
    Luke

    Is your xml stored some where,
    then
    Create datatemplate and use the xml as datasource.
    You can create it using the following sysntax
    <dataTemplate name="Employee" description="L" version="1.0">
    <dataQuery>
    <xml name="xml_emp" expressionPath=".//ROW">
    <url method="GET" realm="" username="" password="">
    file:///C:/dept_employee.xml</url>
    </xml>
    <xml name="xml_dept" expressionPath=".//ROW">
    <url method="GET" realm="" username="" password="">
    file:///C:/dept.xml</url>
    </xml>
    </dataQuery>
    <dataStructure>
    <group name="EMP" source="empxml">
    <element name="NAME" value="ENAME"/>
    your element here
    </group>     
    <group name="DEPT" source="xm_DEPTl">
    <element name="DNAME" value="DPTNAME"/>
    your element from 2nd xml here
    </group>     
    </dataStructure>
    </dataTemplate>
    Now your two xml source will become single source for the report.

  • Problem with extracting Xml data source fields

    Post Author: new_crystal
    CA Forum: Crystal Reports
    Hi,
    I am creating a report which has a xml data source.
    I have a field named fieldvalue in the xml, I need to present this fieldvalue in a column format based on the name of the column heading which is another field in the database called fielddata
    here is what i want
    fielddata1     fielddata2    fielddata3 .......
    fieldvalue1    fieldvalue2   fieldvalue3......
    i have dragged the fieldvalue 3 times in the report and applied different formula for each one of them
    here is the eg. of the formula
    if ( = "A" ) then
    but it is not giving me the correct values pulled from the data source. for the first column it is pulling correctly but for the rest of the columns it is giving values as 0's.
    Can anyone help me out in this? It is pretty urgent!
    Thanks

    Post Author: tel
    CA Forum: Crystal Reports
    I have no idea how to format it in Crystal Reports (i'm new to it too), but if worse comes to worse, you can create an XSLT stylesheet to convert the XML into a format that is easier for Crystal to use. 
    In case you don't know XSLT is a programming language that is designed to convert one XML format into another.

Maybe you are looking for

  • Is there a way to do a "OR" with filters of an Interactive Report?

    Hi, I've noticed for a long time now that when you apply filters on an Interactive Report, they are applied on top of each other. But there is no way to apply them in an 'OR' fashion it seems. Unless I am mistaken. Now I know that you could apply a R

  • Problems editing text in pdf file

    I have a user that is using Adobe Acrobat 8 Standard and is wanting to edit a pdf form that someone sent him.  When we open it and I use the Touchup Text Tool to try and delete some of the text it throws off the entire layout of the document.  Is thi

  • ERROR  IN  FILE--XI--RFC SCENARIO.  BAPI  did not UPDATE the DATABASE TABLE

    Hi I have created a scenario  FILE -XI- RFC File is picked by file adapter  - Its working fine I have used BPM In RFC side  i used BAPI_INCOMINGINVOICE_CREATE Its working fine and return an Invoice Number and Fisical year . When i Check this in the R

  • Is Dreamweaver ready as a corporate tool?

    I have to decide very soon what application our international offices will use in over 15 countries and 45 locations. The total number of purchases will be nearly 75+. But I don't feel confidient about recommending and approving Dreamweaver. I am a f

  • Create organizational charts using application express

    I would like to create organizational charts using the application express(HTMLDB). How do I go about it? I also tried the Aria sample application for HTMLDB 2.0, but when I try to run the scripts it asks for some bind variable parameters ' :NEW ' an