Toplink SP Feature query

Hi,
I am in the process of implementation of Toplink in my project. Was curious when I read that Toplink supports platform independent stored procedures and functions.
Can someone throw some light on this ?
Any responses would be greatly appreciated
Thanks...VJ

TopLink supports calling store procedures on most databases using a platform independent specification, it does not support creating arbitrary stored procedures platform independently.
TopLink also provides some tools in the oracle.toplink.tools.schemaframework package for defining and generating stored procedures on some databases.

Similar Messages

  • JPA/Toplink changes the query logic

    Hi,
    Iam currently using JPA with Toplink implementation , i guess that toplink has its own way of optimizing the provided JPA query ; on another words , toplink sometimes changes the way you are using joins and exists statement to what looks optimized , but unfor. this caused me troubles tracking a query that should work on a certain way but its not cause the generated query by Toplink ( can be captured on the log ) does not represent the same logic , is this a known issue or do i have to write my JPA query on a way on which can be translated correctly by toplink , i know i should provide the query it self , but the model structure is too complex.
    Thanks in advance

    Hello,
    JPQL does not directly translate to SQL, so there might be some differences in what you may be expecting due to JPA requirements on the results that are returned. If there is a problem with specific queries, please let us know and file a bug if it is not behaving the way it should. A workaround would be to use a native SQL query directly.
    Best Regards,
    Chris

  • EJB3 / TopLink EntityManager - invalid query key in expression

    with Glassfish and TopLinka s the entity manager, I'm getting an QueryException that I don't understand. The complaint is that my key (enamelId) is invalid. However I can use the same key in a different query successfully.
    Any thoughts?
    this query gets no complaints:
    SELECT sh FROM Showpiece as sh WHERE sh.enamelId = '0301'
    this query fails:
    SELECT ex FROM Exhibition as ex, Showpiece as sh WHERE sh.enamelId = '0301' AND ex.id = sh.showId
    Exception [TOPLINK-6015] (Oracle TopLink Essentials - 2006.4 (Build 060412)): oracle.toplink.essentials.exceptions.QueryException
    Exception Description: Invalid query key [enamelId] in expression.
    Query: ReportQuery(com.schwarcz.enamels.model.Exhibition)
    at oracle.toplink.essentials.exceptions.QueryException.invalidQueryKeyInExpression(QueryException.java:608)
    at oracle.toplink.essentials.internal.expressions.QueryKeyExpression.validateNode(QueryKeyExpression.java:657)
    at oracle.toplink.essentials.expressions.Expression.normalize(Expression.java:2542)
    at oracle.toplink.essentials.internal.expressions.DataExpression.normalize(DataExpression.java:343)

    I don't remember the specifics of my solution. The base cause was indeed an error in my code. I dimly remember that I had written something so that TopLink was trying to generate a join table and I had defined one as a POJO as well. What I do remember was what I did to find a solution...
    I switched to using the Hibernate entity manager, got some different error messages and was able to correct my code. I now routinely switch back and forth between TopLink and Hibernate. Both seem to me to be pretty likely to produce error messages that are vague and not too helpful.

  • Pagination in toplink using custom query

    Re: Pagination using TopLink
    Posted: Aug 31, 2006 10:42 PM in response to: Shaun Smith Reply
    Hi,
    I have my own customer query which is really complex with subqueries,joins,grouping,aggregation in the query etc etc for which I cant use toplink workbench to create a project and do the metadata mapping.
    But we need to enable pagination without holding the database resources between customer's page time in the browser.
    Is there any provision in toplink to just input the custom query (either statement/prepared statement) and do pagination without holding connection to the database between page time?
    The example i got from the link makes use of LogicalCursor/ChunkingLogicalCursor etc.
    LogicalCursor cursor = new LogicalCursor(Model.class,null);
    for (CursorIterator it = cursor.iterator(session); it.hasNext();)
    System.out.println(it.next(session));
    Only parameter that is passed to the LogicalCursor is "Model" which is a java object mapped to a particular table.
    But we had a java object which should be mapped to the output of a complex query involing complex query and pagination needs to be enabled.
    Could you please let us know a sample by which we can do by simply passing the query during the runtime ?

    It really seems weird.
    We followed the toplink tutorial and wrote a servlet FindAddress which on receiving the request
    1. instantiates ReadQuery and
    2. setreferenceclass to Address.class,
    3. setFetchSize(1000) and
    4.sets useScrollableCursor.
    5. It does session.executeQuery returning a ScrollableCursor.
    6. We place the ScrollableCursor in HttpSession
    and then redirect the page to viewAddress.jsp which
    1. retrieves the ScrollableCursor from the session
    2. i=0;     while(cursor.hasNext() && i<1000) {
         Address address = (Address)cursor.next();
    //display via the jsp all these 1000 address objects
    3. has a next button when a click on that it again goes to the same page retrieving the next set of 1000 records from ScrollableCursor from the session.
    Through out this experimentation I could see the connection is still held. I was expecting that once the page gets displayed for 1000 records and untill you press next, the connection should be handled back to the J2EE application server but still the connection is held .
    The logic of setFetchSize as mentioned in the documentation is that after reading the first set of records as per fetchSize ,connection should be returned to the pool and when we do iterator.next() after fetchsize limit, it has to again going to the database and fetch records but it doesnt seem to be.
    Could you please help us. This is what we are trying to do as next step and we had been evaluating toplink could be the best choice for our business scneario:
    We try to achieve pagination without holding the database resource when the user navigates between paged records.
    Any help on this would make us to hit toplink for our huge application.
    Here is the attached FindAddress.java and ViewAddress.jsp
    FindAddress.java
    =============
    // Decompiled by DJ v2.9.9.61 Copyright 2000 Atanas Neshkov Date: 9/8/2006 6:32:21 PM
    // Home Page : http://members.fortunecity.com/neshkov/dj.html - Check often for new version!
    // Decompiler options: packimports(3)
    // Source File Name: FindAddress.java
    package examples.servletjsp;
    import java.io.IOException;
    import java.io.PrintStream;
    import javax.servlet.*;
    import javax.servlet.http.*;
    import oracle.toplink.expressions.Expression;
    import oracle.toplink.expressions.ExpressionBuilder;
    import oracle.toplink.queryframework.ReadAllQuery;
    import oracle.toplink.queryframework.ScrollableCursor;
    import oracle.toplink.threetier.ClientSession;
    import oracle.toplink.threetier.Server;
    // Referenced classes of package examples.servletjsp:
    // JSPDemoServlet
    public class FindAddress extends JSPDemoServlet
    public FindAddress()
    public void doGet(HttpServletRequest request, HttpServletResponse response)
    throws ServletException, IOException
    doPost(request, response);
    public void doPost(HttpServletRequest request, HttpServletResponse response)
    throws ServletException, IOException
    request.setCharacterEncoding("UTF-8");
    getServletContext().log("FindAddress servlet - doPost");
    java.util.Vector address = null;
    ScrollableCursor cursor = null;
    try
    HttpSession session = request.getSession(true);
    ReadAllQuery query = new ReadAllQuery();
    query.setReferenceClass(examples.servletjsp.model.Address.class);
    ExpressionBuilder builder = new ExpressionBuilder();
    query.setSelectionCriteria(builder.get("id").greaterThan(100));
    query.setFetchSize(5000);
    query.useScrollableCursor();
    System.out.println("########### Sleep Mode Before assigning to CURSOR ###############");
    System.out.println("############ Back from Sleep Mode before CURSOR ############");
    cursor = (ScrollableCursor)((Server)getSession()).acquireClientSession().executeQuery(query);
    System.out.println("############ Sleep Mode After assigning to CURSOR ###########");
    System.out.println("############ Back from Sleep Mode After CURSOR ############");
    session.setAttribute("ScrollableCursor", cursor);
    catch(Exception e)
    request.setAttribute("source", "FindEmployees doPost");
    request.setAttribute("header", "An Error Occurred");
    request.setAttribute("errorMessage", e.getMessage());
    request.getRequestDispatcher("./errorPage.jsp").forward(request, response);
    return;
    System.out.println("cursor------------" + (cursor == null));
    if(cursor == null)
    request.getRequestDispatcher("./EmployeesNotFound.jsp").forward(request, response);
    } else
    request.setAttribute("address", address);
    request.getRequestDispatcher("./viewAddress.jsp").forward(request, response);
    viewAddress.jsp
    =============
    <%@page import="java.util.*"%>
    <%@page import="examples.servletjsp.*"%>
    <%@page import="examples.servletjsp.model.*"%>
    <%@page import="oracle.toplink.queryframework.ScrollableCursor"%>
    <%@page import="java.math.*"%>
    <%@page contentType = "text/html; charset=UTF-8"%>
    <html>
    <head><title>Employee Query Results</title></head>
    <body>
    <form name="test" method="post" action="viewAddress.jsp">
    <!--      Prepare s heading.
         Get the employees passed in from ViewEmployees servlet. Show them in table format. Provide button
         to ViewEmployee -->
    <%
         request.setCharacterEncoding("UTF-8");
         String searchString = request.getParameter("employeeString");
         ScrollableCursor cursor = (ScrollableCursor) session.getAttribute("ScrollableCursor");
         String heading = null;
              heading="Search Results for FindAll on Employee";
         String employeeData = "";
         //Iterator data = ((Vector)request.getAttribute("address")).iterator();
         int i =0;
         while(cursor.hasNext() && i<4995) {
              if(i<10){
                   System.out.println("######### JSP Count TRhread Sleep ###########");
                   //Thread.sleep(100);
                   //System.out.println("######### JSP Count TRhread Sleep Over ###########");
              i++;
         Address address = (Address)cursor.next();
         BigDecimal id = address.getId();
         String city = address.getCity();
         String province = address.getProvince();
         String street = address.getStreet();
         String country = address.getCountry();
         String pCode = address.getPostalCode();
         employeeData += "<tr><td>" + id + "</td>"
              + "<td>" + province + "</td>"
              + "<td>" + street + "</td>"
              + "<td>" + city + "</td>"
              + "<td>" + pCode + "</td>"
              + "<td>" + country+ "</td>"
              + "</tr>";
         //cursor.close();
         System.out.println("abcdAfter closing the cursor ->plz see whether connpool monitorcnt = 0");
    %>
    <center>
         <h2><%=heading%></h2>
         <hr>
         Return to Main
         <p>
         <table border=1>
              <tr>
                   <td align="center">Address Id</td>
                   <td align="center">Province</td>
                   <td align="center">Street</td>
                   <td align="center">City</td>
                   <td align="center">Postal Code</td>
                   <td align="center">Country</td></tr>
              <%=employeeData %>
         </table>
    </center>
    <p>
    <input type="submit" name ="next" value="next" >
    <center>Return to Main</center>
    </form>
    </body>
    </html>

  • We've updated computers at the radio station...now missing an 'important' FX feature query

    Good Morning fellow users,
    We've updated our computers at the 6 radio stations I work for...all 6 production rooms and studios (for those not using VoxPro, myself included:)) to newer, core 'i' machines from the old school Pentium 4s we had which were on their last let (yet ran Audition 3.X) just fine. The newer machines are nice. They're signifcantly quicker chewing through mp3s, conversion betweeen and to different formats...but obviously, it's older softare that isn't able to take advantage of 64Bit or Multiple cores...so other than having a more reliable, speedier version...until we can convince the 'suits' to be that we need to bump up to the latest version, we'll be using said 3.X
    That said, one of the main features we've been unable to figure out how to get back to our defaut 'edit' screen is the little volume knob that pops up while a segment of the audio is selected. IE, you've clicked and dragged a portion of the existing audio in the edit screen to 'turn it white'. In the little area above selected audio file, in the 'white/selected' area....we (used to) have a small volume icon that allowed for automatic amplifcation with a simple click and drag of the mouse (either right or left for volume 'up or down'). It looks as though the engineer did re-image each machine with the corporate Audition disc---however, it's showing as Audition 3.0 in the "About Audition" tab under Help. Isn't or wasn't there an updated to at least 3.1 or 3.01?  Just wanted to double check as I run the 'new' Audition on my Macs for my home business--and I'm really enjoying it:)  However...3.X, IMHO is one of, if not THE Best Wave editor...for it's time, in the History of Wave/Simple editing and production on the run. Since the Syntrillium/Cool Edit days, I've used it (since transitioning from SAW in the mid 90's).  So it's been a bit tough to get acquainted with my Mac version....I just don't see the update happening in 'corporate' radio for some time. It took a whole lotta time, effort, and bureaucratic BS just to get the new hardware. We'll go to battle for the software in this year's budget (not to be distributed til next year---likely 3rd or 4th quarter:))....so must make do with the 3.X for now.
    Lastly, we're gettin a studder after a quick edit. Say I'm cutting a 30 second spot...4 or 5 seconds of dead handles, maybe a slip in the middle...total of 43 second sound file. I quickly cut the front handle, but left click dragging to the start, hit delete, hit space bar....studder, studder for about 2-3 seconds before it works itself out. Is there a cache setting I'm missing somewhere? If I go back and play from the beginning the file is just fine. No issues. Just that initial playback after edit. It's annoying but not a deal killer. Easily gotten used to. 
    In radio, as our jobs (and hats we wear) have become more and more "Life in the production room" producing for smaller markets, voice-tracking, commercial and audio produciton/voice over--again, for the smaller markets that these days are running 'jock-less'....Audition has easily become my number 1 tool in the box. Just a couple quirks I'd like to get worked out for the rest of our air/prod staff. I was, in fact, very happy with the older machines---each of our 'Workspaces' set up as we liked. Unfortunately, we ALL know how the engineers work. They get the new machines, pull the old, re-image and THEN send out that email. Ugghhhhh!  After almost 30 years in the buz, I sometimes miss when ALL they dealt with was RF and transmitters:)  We fixed our own 'work-stations' by writing out 3x5" index cards and bulk erasing carts, donuts (reels), and opening fresh, new vinyl from the labels:)
    Thanks for your time!
    Jer

    Thanks MusicConductor
    Have I in some way 'messed' with the RealTek driver by disabling sounds? After reading your reply I actually went and looked at the back panel of the computer. I was blown away...as you're correct, we are using the internal/stock sound card!  That's never been the case, as our engineer has always put a pro card---usually, if memory serves, a PCI/PCI-E Digigram card. However...with this new workstation he put in, he's utilizing the onboard, RealTek software/stock internal solution.  To date, it's worked well...however, Audition crashed last week and we had to do a full install of the program again yesterday. Cut both yesterday and today's shows and the stuttering is back. Sounds in Windows are 'off' and cache/buffer sizes have been increased. I'll continue to play this week...and I still have to update to 3.01 after the fatal error with the software last week.
    Thanks again...and if there's something I should not do with the Realtek software, can you be more specific?  I'm not sure I've messed with anything pertinent. We've got both ins and outs (from the sound card) separated into stereo RCA for both in and output. Sound quality seems to be just fine. (No noise/hiss or otherwise unnecessary or unwanted artifacts).  Maybe this is the issue. The onboard sound card. As I mentioned, in past systems we've used Lynx or Digigram pro cards. I'm kind of surprised to see us using the internal/stock card. As you say though, we've gone through some evolution with the isolation and performance of on board sound.  The RealTek driver version is 6.0.1.6392. One other question....in 'shared' mode...should I be running 24bit 48000Hz or 24bit 44100Hz?  Again...this is primarily used for saving down to MP3, transferring to our proprietary "Next Gen" system in generic MP3 flavor...so Next Gen can wrap it in it's own proprietary WAV format. In this case, is there a reason I shouldn't just be running it at 16bit 44100? In the control panel I have it set to 'No sounds' in sound scheme and in the lower "Program Events' box, I've selected '(None)'. Is this as 'deep' as I can get in the sound settings?
    Thanks again. This stuttering isn't normal...and with the inherent speed increase (CPU) and RAM update, as well as a speedier drive (7200rpm), I'm not sure the cause. The last and older system (Pentium IV) was also updated to Windows 7---so it did work fine with the current OS albeit on the older spec'ed machine.
    J

  • Acrobat Licensing and feature query

    can i install acrobat 5 standard with acrobat 9 professional version? Also can you please share the feature comparison between acrobat 5.0 Std and 9 Pro?

    There is not simple comparison chart between these two versions. Normally, you would not install both AA5 and AA9 on the same machine. There are some items that are used in common and those do not interact well in most cases, particularly with a 4 version separation. Why would you want to install AA5 on the same machine anyway, there is no need?

  • RMAN clone feature query

    Hello DBA's,
    Using a 9i Solaris box and i need to perfom a RMAN clone of prod (target db) to train database. Train database does already exist.
    I've performed "backup database plus acrhivelog all delete input" (on prod)
    My query is when i do run "duplicate target database to traindb" will it refresh all the existing datafiles already in TRAIN db or will i need to manually drop the datafiles or even 'drop' the TRAIN database?
    Many thanks!

    You should remove or drop TRAIN DB before you clone over from PROD.
    However, you can use the NOFILENAMECHECK clause
    http://download.oracle.com/docs/cd/B19306_01/backup.102/b14194/rcmsynta028.htm#sthref466

  • 10g Feature Query/Request

    Is it possible to set the tab size to different amounts for different file types? For instance, I like my Java source code to have a relatively large indentation, as I believe this enhances readability. However, XML files tend to have much deeper nesting, and therefore a large tab size quickly results in having to scroll the document to the right to see the innermost content. Anything nested this deeply in source code is probably bad code and should be refactored, but this happens all the time in UIX, for example, since almost every tag needs an additional 'contents' tag.
    I can only find one global tab size setting in the 'Code Editor' properties. If there isn't currently any way to set this size differently for individual file types, please consider this feature for future releases.

    You can tell Apple your wishes directly using this link: http://www.apple.com/feedback/iphone.html

  • CS4 feature query

    Does the sixth version of InDesign finally remember print settings properly? That is, it remembers range but resets quantity to 1. It's getting awfully frustrating (even for Adobe) that they keep changing it, and it keeps getting worse.

    Put feather back to zero?

  • Feature query: Does Adobe Audition 3.0 zoom with marker still on screen?

    I'm considering upgrading from 1.5 to 3.0 but on the condition that the following annoyance is resolved.
    When editing, either Multi or Single view, I have the yellow dotted marker marking a position in the waveform.
    Now if I zoom in, Audition zooms to a nearby region but not where I had the yellow dotted marker. So I have to scroll back/forward to find the region where the marker is.
    This is very annoying. Why doesn't audition zoom to the region where the marker is? That is what I want.
    Searched forum for 'zoom' but not seen this problem already.

    You haven't seen this problem in the forums because it isn't a problem. It doesn't zoom into the region of the yellow marker unless you click on the correct zoom button in the box next to the playback/record control box. This "view" box has been there for every version of this program since I've been using it (Cool Edit Pro 1.x for me).
    This is a user-to-user forum, not a direct complaint line to Adobe, and as such we don't really care if you do or do not upgrade so you can stop with the statements of conditions you have for upgrading. Not knowing how to use the basic zoom functions of the program or going live on the radio with a mixdown before even listening to it are not the fault of the program but rather the fault of the user.

  • Feature query/request:Home button functionality (triple & quadruple clicks)

    Hi all,
    I severely lack the ability to bind the triple-click on the home button on my iPhone 3GS to something useful. For me, that would be to access the "add new inbox item" in Omnifocus. For others, it could be opening the voice memos app and starting to record audio. Is it possible to enable this functionality (accessing app specific functionality, with bonus points for doing this when the iPhone is locked) without resorting to jailbreak? Is this functionality something anyone else would find welcome?
    Oh, and in the perfect world, a quadruple click would start a recording of audio, inside a new inbox item within Omnifocus. This is an accessibility settings that would make my iPhone and its workflow more accessible to me.

    You can tell Apple your wishes directly using this link: http://www.apple.com/feedback/iphone.html

  • Toplink as OR-Mapper for ADF BC?

    Hi,
    I just had a look at Steve Muench's PPTs from Croatia OUG, especially at the ppt "jdev 10.1.3 new features": (http://radio.weblogs.com/0118231/2005/10/21.html#a614).
    On slide 47/57 there is a slightly modified new picture of the adf 10.1.3 architecture.
    Most interesting change: now there is a new layer called "toplink data services", suggesting that also ADF BC persistence is done via toplink.
    Could someone please point out, if that's a vision or concrete feature?
    Thanks!
    Torsten

    I borrowed that slide from a marketing presentation that had tried to simplify the picture a bit. I've replaced it now with one that is more technically accurate for the 10.1.3 release timeframe with regard to the ADF layers. Toplink does feature a number of different backend-technology solutions as pictured in the original slide. It's just that showing that on the same slide as the various supported ADF data control options turned to require four-dimensional graphics, so they went for the simplified picture. You can read more on the idea of a toplink data services layer in this JDJ interview with Dennis Leung: http://java.sys-con.com/read/47361.htm
    As is has always done, ADF Business Components inherit their own high-performance, relationally-focused query and persistence functionality from the framework base classes.
    For the future, we are researching the ability to leverage the POJO persistence standard in JSR 220, implemented by toplink as part of their EJB3 work, to persist the ADF BC Entity POJO objects, too. This would give ADF BC users new mapping options over the default ones we already provide -- which in practice turn out to be what you mostly use in practice, but more flexibility would still be nice. Last I checked, the standard only supported persisting a POJO class which extended from another mapped POJO, and not from some arbitrary framework base class, so unless they've recently relaxed that restriction, anyone using a framework base class to add globally useful application-building functionality to their persistent POJO's won't yet be able to persist them with the EJB3 spec just yet. This of course includes an ADF Entity Object class, since it inherits functionality from a base EntityImpl framework class.

  • Use of current time for polling Database Adapter query

    I am writing a simple BPEL process with a Polling Database Adapter and a Recieve. The idea is that we are polling an XE database for any entries in a TRIP table which have an expiration date/time field that has passed.
    The Adapter was build using JDeveloper 10.1.3.2 (with Oracle Application Server patched to 10.1.3.3.0) as a "Poll for New Changed Records in a Table" Operation type with a STATUS field (0 for live, 1 for expired) as the Logical Delete Field.
    I was unable to find a way to generate a SELECT query expression with the wizard that would allow me to use current/system time as an attribute, so I finished the wizard and edited the Toplink Descriptor to use a custom SQL expression for the query. This resulted in the following code in the toplink_mappings.xml file:
    <?xml version="1.0" encoding="UTF-8"?>
    <toplink:object-persistence version="Oracle TopLink - 10g Release 3 (10.1.3.1.0) (Build 061004)"
    xmlns:opm="http://xmlns.oracle.com/ias/xsds/opm" xmlns:xsd="http://www.w3.org/2001/XMLSchema"
    xmlns:toplink="http://xmlns.oracle.com/ias/xsds/toplink"
    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
    <opm:name>ExpiredTripPoller</opm:name>
    <opm:class-mapping-descriptors>
    <opm:class-mapping-descriptor xsi:type="toplink:relational-class-mapping-descriptor">
    <opm:class>ExpiredTripPoller.Trip</opm:class>
    <opm:alias>Trip</opm:alias>
    <opm:primary-key>
    <opm:field table="TRIP" name="ID" xsi:type="opm:column"/>
    </opm:primary-key>
    <opm:events xsi:type="toplink:event-policy"/>
    <opm:querying xsi:type="toplink:query-policy">
    <opm:queries>
    <opm:query name="ExpiredTripPoller" xsi:type="toplink:read-all-query">
    <toplink:timeout>0</toplink:timeout>
    <toplink:call xsi:type="toplink:sql-call">
    <toplink:sql>SELECT ID, LPN, START_TIME, EXPIRY_TIME, STATUS FROM TRIP WHERE ((STATUS = '0') AND (EXPIRY_TIME < SYSDATE)) ORDER BY EXPIRY_TIME ASC</toplink:sql>
    </toplink:call>
    <toplink:reference-class>ExpiredTripPoller.Trip</toplink:reference-class>
    <toplink:cache-usage>primary-key</toplink:cache-usage>
    <toplink:lock-mode>none</toplink:lock-mode>
    <toplink:container xsi:type="toplink:list-container-policy">
    <toplink:collection-type>java.util.Vector</toplink:collection-type>
    </toplink:container>
    </opm:query>
    <opm:query name="findAllTrip" xsi:type="toplink:read-all-query">
    <toplink:timeout>0</toplink:timeout>
    <toplink:reference-class>ExpiredTripPoller.Trip</toplink:reference-class>
    <toplink:cache-usage>primary-key</toplink:cache-usage>
    <toplink:lock-mode>none</toplink:lock-mode>
    <toplink:container xsi:type="toplink:list-container-policy">
    <toplink:collection-type>java.util.Vector</toplink:collection-type>
    </toplink:container>
    </opm:query>
    </opm:queries>
    <toplink:does-exist-query xsi:type="toplink:does-exist-query">
    <toplink:existence-check>check-database</toplink:existence-check>
    </toplink:does-exist-query>
    <toplink:read-all-query xsi:type="toplink:read-all-query">
    <toplink:reference-class>ExpiredTripPoller.Trip</toplink:reference-class>
    <toplink:container xsi:type="toplink:list-container-policy">
    <toplink:collection-type>java.util.Vector</toplink:collection-type>
    </toplink:container>
    </toplink:read-all-query>
    </opm:querying>
    <opm:attribute-mappings>
    <opm:attribute-mapping xsi:type="toplink:direct-mapping">
    <opm:attribute-name>id</opm:attribute-name>
    <opm:field table="TRIP" name="ID" xsi:type="opm:column"/>
    <opm:attribute-classification>java.math.BigDecimal</opm:attribute-classification>
    </opm:attribute-mapping>
    <opm:attribute-mapping xsi:type="toplink:direct-mapping">
    <opm:attribute-name>lpn</opm:attribute-name>
    <opm:field table="TRIP" name="LPN" xsi:type="opm:column"/>
    <opm:attribute-classification>java.lang.String</opm:attribute-classification>
    </opm:attribute-mapping>
    <opm:attribute-mapping xsi:type="toplink:direct-mapping">
    <opm:attribute-name>startTime</opm:attribute-name>
    <opm:field table="TRIP" name="START_TIME" xsi:type="opm:column"/>
    <opm:attribute-classification>java.sql.Timestamp</opm:attribute-classification>
    </opm:attribute-mapping>
    <opm:attribute-mapping xsi:type="toplink:direct-mapping">
    <opm:attribute-name>expiryTime</opm:attribute-name>
    <opm:field table="TRIP" name="EXPIRY_TIME" xsi:type="opm:column"/>
    <opm:attribute-classification>java.sql.Timestamp</opm:attribute-classification>
    </opm:attribute-mapping>
    <opm:attribute-mapping xsi:type="toplink:direct-mapping">
    <opm:attribute-name>status</opm:attribute-name>
    <opm:field table="TRIP" name="STATUS" xsi:type="opm:column"/>
    <opm:attribute-classification>java.math.BigDecimal</opm:attribute-classification>
    </opm:attribute-mapping>
    </opm:attribute-mappings>
    <toplink:descriptor-type>independent</toplink:descriptor-type>
    <toplink:caching>
    <toplink:cache-type>weak-reference</toplink:cache-type>
    <toplink:always-refresh>true</toplink:always-refresh>
    </toplink:caching>
    <toplink:remote-caching>
    <toplink:cache-type>weak-reference</toplink:cache-type>
    </toplink:remote-caching>
    <toplink:instantiation/>
    <toplink:copying xsi:type="toplink:instantiation-copy-policy"/>
    <toplink:change-policy xsi:type="toplink:deferred-detection-change-policy"/>
    <toplink:tables>
    <toplink:table name="TRIP"/>
    </toplink:tables>
    </opm:class-mapping-descriptor>
    </opm:class-mapping-descriptors>
    </toplink:object-persistence>
    To test I used the above custom SQL at the command line and it filtered the records by EXPIRY_TIME as expected.
    When deployed, the polling process updates the STATUS file dof table entries, but all entries with status 0 regardless of EXPIRY_DATE. My modification appears to be being ignored. I was unsure as to whether the QUERY was being determined in some other way so I modified the descriptor (with the toplink expression editor) to compare against a literal time value, producing the following modified toplink_mappings.xml:
    <?xml version="1.0" encoding="UTF-8"?>
    <toplink:object-persistence version="Oracle TopLink - 10g Release 3 (10.1.3.1.0) (Build 061004)"
    xmlns:opm="http://xmlns.oracle.com/ias/xsds/opm" xmlns:xsd="http://www.w3.org/2001/XMLSchema"
    xmlns:toplink="http://xmlns.oracle.com/ias/xsds/toplink"
    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
    <opm:name>ExpiredTripPoller</opm:name>
    <opm:class-mapping-descriptors>
    <opm:class-mapping-descriptor xsi:type="toplink:relational-class-mapping-descriptor">
    <opm:class>ExpiredTripPoller.Trip</opm:class>
    <opm:alias>Trip</opm:alias>
    <opm:primary-key>
    <opm:field table="TRIP" name="ID" xsi:type="opm:column"/>
    </opm:primary-key>
    <opm:events xsi:type="toplink:event-policy"/>
    <opm:querying xsi:type="toplink:query-policy">
    <opm:queries>
    <opm:query name="ExpiredTripPoller" xsi:type="toplink:read-all-query">
    <opm:criteria operator="lessThan" xsi:type="toplink:relation-expression">
    <toplink:left name="expiryTime" xsi:type="toplink:query-key-expression">
    <toplink:base xsi:type="toplink:base-expression"/>
    </toplink:left>
    <toplink:right xsi:type="toplink:constant-expression">
    <toplink:value xsi:type="xsd:date">2007-07-30</toplink:value>
    </toplink:right>
    </opm:criteria>
    <toplink:timeout>0</toplink:timeout>
    <toplink:reference-class>ExpiredTripPoller.Trip</toplink:reference-class>
    <toplink:cache-usage>primary-key</toplink:cache-usage>
    <toplink:lock-mode>none</toplink:lock-mode>
    <toplink:container xsi:type="toplink:list-container-policy">
    <toplink:collection-type>java.util.Vector</toplink:collection-type>
    </toplink:container>
    </opm:query>
    <opm:query name="findAllTrip" xsi:type="toplink:read-all-query">
    <toplink:timeout>0</toplink:timeout>
    <toplink:reference-class>ExpiredTripPoller.Trip</toplink:reference-class>
    <toplink:cache-usage>primary-key</toplink:cache-usage>
    <toplink:lock-mode>none</toplink:lock-mode>
    <toplink:container xsi:type="toplink:list-container-policy">
    <toplink:collection-type>java.util.Vector</toplink:collection-type>
    </toplink:container>
    </opm:query>
    </opm:queries>
    <toplink:does-exist-query xsi:type="toplink:does-exist-query">
    <toplink:existence-check>check-database</toplink:existence-check>
    </toplink:does-exist-query>
    <toplink:read-all-query xsi:type="toplink:read-all-query">
    <toplink:reference-class>ExpiredTripPoller.Trip</toplink:reference-class>
    <toplink:container xsi:type="toplink:list-container-policy">
    <toplink:collection-type>java.util.Vector</toplink:collection-type>
    </toplink:container>
    </toplink:read-all-query>
    </opm:querying>
    <opm:attribute-mappings>
    <opm:attribute-mapping xsi:type="toplink:direct-mapping">
    <opm:attribute-name>id</opm:attribute-name>
    <opm:field table="TRIP" name="ID" xsi:type="opm:column"/>
    <opm:attribute-classification>java.math.BigDecimal</opm:attribute-classification>
    </opm:attribute-mapping>
    <opm:attribute-mapping xsi:type="toplink:direct-mapping">
    <opm:attribute-name>lpn</opm:attribute-name>
    <opm:field table="TRIP" name="LPN" xsi:type="opm:column"/>
    <opm:attribute-classification>java.lang.String</opm:attribute-classification>
    </opm:attribute-mapping>
    <opm:attribute-mapping xsi:type="toplink:direct-mapping">
    <opm:attribute-name>startTime</opm:attribute-name>
    <opm:field table="TRIP" name="START_TIME" xsi:type="opm:column"/>
    <opm:attribute-classification>java.sql.Timestamp</opm:attribute-classification>
    </opm:attribute-mapping>
    <opm:attribute-mapping xsi:type="toplink:direct-mapping">
    <opm:attribute-name>expiryTime</opm:attribute-name>
    <opm:field table="TRIP" name="EXPIRY_TIME" xsi:type="opm:column"/>
    <opm:attribute-classification>java.sql.Timestamp</opm:attribute-classification>
    </opm:attribute-mapping>
    <opm:attribute-mapping xsi:type="toplink:direct-mapping">
    <opm:attribute-name>status</opm:attribute-name>
    <opm:field table="TRIP" name="STATUS" xsi:type="opm:column"/>
    <opm:attribute-classification>java.math.BigDecimal</opm:attribute-classification>
    </opm:attribute-mapping>
    </opm:attribute-mappings>
    <toplink:descriptor-type>independent</toplink:descriptor-type>
    <toplink:caching>
    <toplink:cache-type>weak-reference</toplink:cache-type>
    <toplink:always-refresh>true</toplink:always-refresh>
    </toplink:caching>
    <toplink:remote-caching>
    <toplink:cache-type>weak-reference</toplink:cache-type>
    </toplink:remote-caching>
    <toplink:instantiation/>
    <toplink:copying xsi:type="toplink:instantiation-copy-policy"/>
    <toplink:change-policy xsi:type="toplink:deferred-detection-change-policy"/>
    <toplink:tables>
    <toplink:table name="TRIP"/>
    </toplink:tables>
    </opm:class-mapping-descriptor>
    </opm:class-mapping-descriptors>
    </toplink:object-persistence>
    On deployment, this version of the BPEL process behaved as expected - only modifying the records with EXPIRY_TIME less thatn the literal time specified. (Also, I can't really pass in the time as a parameter as this is a polling model).
    Can anyone shed any light on what is happening or suggest how I might go about polling in the desired way?
    Cheers

    Please take a look at this article which states SYSDATE is not supported in a
    where clause.
    http://www.oracle.com/technology/pub/articles/bpel_cookbook/qualcomm-bpel.html
    Excerpt from the article:
    Here are three important things you should do in implementing the above design:
    Have the status of the record being processed stored in the database. The status includes the process state, next process attempt time, and processing attempt count.
    Create an updatable view that exposes only records that are ready to be processed. A view is needed because the database adapter cannot handle a where clause that compares against SYSDATE.
    Design logic that determines if a process instance that has faulted should be retried and when the retry should occur. This information will be updated in the database by use of a stored procedure. This can also be done with an update partner link and additional logic in BPEL.
    mahalo,
    a iii

  • An extra column of a query in an ADF Faces Table?

    Hi to all OTN Community...
    I use ADF Faces, Toplink and EJB 3.0 in JDevelooper 10.1.3.1.0, and i have a question...
    I need to show in an adf faces table, the result of a query like this
    SELECT COLUMN1, COLUMN2, COUNT(*)
    FROM TABLEX
    GROUP BY COLUMN1, COLUMN2
    I do this query in the TableX named queryes...and then i have acces to this named query in the dataControl, but, when i drag and drop the dataControl to a jsf page, this only shows the columns of the tableX. Then, i want to know, ¿How can i show the count(*) column in the page in a dataControl?
    PD: i want to show in the adf faces table the same result if i execute that query in an sql client.
    Thanx in advance...
    Darklorddany

    Darklorddany,
    The solution to this is to add an additional method on your EJB 3.0 session-bean that exposes an dynamic TopLink report (projection) query.
    The TopLink code within the method would leverage your existing TopLink mappings to do the query like:
            ReportQuery rq = new ReportQuery(Employee.class, new ExpressionBuilder());
            rq.addAttribute("firstName");
            rq.addAttribute("lastName");
            rq.addCount();
            rq.addGrouping("firstName");
            rq.addGrouping("lastName");
            List<ReportQueryResult> results = (List<ReportQueryResult>)session.executeQuery(rq);The ReportQueryResult objects are very generic map/row type containers that will not work well in your ADF binding layer. With JPA you can specify and ad-hoc Java class to contain such projection results that make them a little easier to use in clients. This functionality will be available in the next release of TopLink. Until then you will need to write some code to convert to your own result class for this query.
    In my case I'll create a simple POJO like:
        public class EmployeeNameCount {
            private String firstName;
            private String lastName;
            private int count;
            public EmployeeNameCount(String firstName, String lastName, int count) {
                this.firstName = firstName;
                this.lastName = lastName;
                this.count = count;
            public String getFirstName() {
                return this.firstName;
            public String getLastName() {
                return this.lastName;
            public int getCount() {
                return this.count;
        }Now I combine the previous report query code into an EJB 3.0 session bean method:
        @TransactionAttribute(TransactionAttributeType.SUPPORTS)
        public List<EmployeeNameCount> findEmployeeNamesWithCount() {
            Session session = getSessionFactory().acquireSession();
            ReportQuery rq = new ReportQuery(Employee.class, new ExpressionBuilder());
            rq.addAttribute("firstName");
            rq.addAttribute("lastName");
            rq.addCount();
            rq.addGrouping("firstName");
            rq.addGrouping("lastName");
            List<ReportQueryResult> results = (List<ReportQueryResult>)session.executeQuery(rq);
            session.release();
            List<EmployeeNameCount> empNameCounts = new ArrayList<EmployeeNameCount>(results.size());
            for (ReportQueryResult rqr: results) {
                String fname = (String)rqr.getByIndex(0);
                String lname = (String)rqr.getByIndex(1);
                int count = ((Number) rqr.getByIndex(2)).intValue();
                empNameCounts.add(new EmployeeNameCount(fname, lname, count));   
            return empNameCounts;
        }You will also need to make sure the method exists on your EJB 3.0 session bean's interface as well. Then regenerate the data control for your session bean and you should have access to drag and drop this query with its results into your JSF pages.
    As mentioned this use case will be much simpler and declarative in the next release.
    Doug

  • Query Browser not available in Dashboards appl !?

    Hello,
    We installed SAP BO Dashboards 4.1 SP2 (14.1.2.1121) and want to use universe queries in the dashboard.
    The workspace feature "Query Browser" is empty.
    We don't get the icons to logon to BOXI (to universe).
    Is this an installation issue? What do we need to check?
    Thanks,
    Bernd

    Hi Bernd,
    Happy to hear that, but please be aware using excel 2013 with dashboard designer. Most of the time it make issue in integrating with the data. Lot of discussions are happened regarding this. Few are listed below.
    Excel 2013 and SAP BusinessObjects Dashboards 4.1 Support Pack1 version 14.1.1.1036
    SAP BO Dashboard 4.1 Support pack 1, exported swf file URL component problem - Office 2013
    Better to go with the Excel 2010. Just felt to highlight the issues before going deep into the design.
    --SumanT

Maybe you are looking for

  • My finder wont open when i turn on my mac.

    I would simply turn on my Mac, but Finder wont open and it wont let me open other apps, the only thing that opens up is Safari, other than that i cant open anything else! I don't know whats wrong.

  • WiFi setup

    I have the same problem. I am at my home with an unsecured wireless network, my BB recognizes the wi-fi but will not allow me to connect and surf the web. We have an iphone and samsung handsets and both are simple to hook into wi-fi, but the BB, not

  • Lost software recovery usb

    I have lost my software recovery usb that came with my macbook air. Is it possible to get a replacement and if so how?

  • Re: College Student Deals: No confirmati​on email!

    I too am having the same issue. My son submitted his .edu email 3 days ago and he still has not received the email. I've verified his college inbox doesn't block marketing emails. Please help! Thanks.

  • JDeveloper 11g and 64bit Java

    Hi everyone. I have just installed JDeveloper 11g on my 64bit CentOS machine and everything worked as expected. Then I tried to use my 64bit JDK version 1.6.0.10 and after a little bit of tampering with the installation directories I was able to do t