More binding params in ViewLink assoc clause in 10g

I'm using a ViewLink with assoc. clause which uses more times 1 binding parameter. The expression :1 ... is taken as a question mark ? and when is used more times, the next attribute is required. Also, it doesn't care the number used behind the colon (:).
The numbers behind the colon were resolved in 9i and ViewLinks with clauses like:key in (select fk1 from rel1 where fk1=:1 union select fk2 from rel2 where fk2=:1)worked properly.
Is there any way to use this feature as before?
Thanks for any suggestions.

I'm using a ViewLink with assoc. clause which uses more times 1 binding parameter. The expression :1 ... is taken as a question mark ? and when is used more times, the next attribute is required. Also, it doesn't care the number used behind the colon (:).
The numbers behind the colon were resolved in 9i and ViewLinks with clauses like:key in (select fk1 from rel1 where fk1=:1 union select fk2 from rel2 where fk2=:1)worked properly.
Is there any way to use this feature as before?
Thanks for any suggestions.

Similar Messages

  • More binding params in ViewLink assoc clause in 10g (10.1.2)

    I'm using a ViewLink with assoc. clause which uses more times 1 binding parameter. The expression :1 ... is taken as a question mark (?) and when is used more times, the next attribute is required. Also, it doesn't care the number used behind the colon (:).
    The numbers behind the colon were resolved in 9i and ViewLinks with clauses like:
    key in (select fk1 from rel1 where fk1=:1 union select fk2 from rel2 where fk2=:1)worked properly.
    Is there any way to use this feature as before?
    Thanks for any suggestions.

    My first thought is that you suggest the app server to database connection is timing out - I'm assuming you're not using the load balancer to balance sqlnet connections so are we actually talking about a firewall in between and not the Big IP?
    If it is the load balancer then, looking at this another way... on Cisco CSS 11500 series you can definitely set the timeout on the load balancer to a specific value (or to never timeout), so you can probably do the same on the Big IP.
    Note: I wouldn't recommend setting the connections to never timeout as this can potentially waste memory on your load balancers which might look like a memory leak after, say, 6 months in a production environment without a reboot.
    Hope this helps.

  • XSQL Using bind params with sql LIKE clause

    I am unable to use a bind-param with the LIKE clause in a SELECT statement.
    eg call .../temp.xsql?name=N
    XSQL query is this:
    <xsql:query max-rows="-1" bind-params="name">
    SELECT last_name
    FROM emp
    WHERE last_name LIKE '?%'
    </xsql:query>
    I have tried a few combinations so far with no success eg:
    WHERE last_name LIKE '{@name}%'
    WHERE last_name LIKE ?||%
    Any ideas?

    I highly recommend using XSQL's real bind variable feature wherever you can. You can read about it in the XSQL Online Documentation (Search for the "Using Bind Variables" section).
    Using this feature is more performant and more secure than using textual substitution variables.
    Here's what your page looks like using textual substitution:
    <page connection="UTD4" xmlns:xsql="urn:oracle-xsql">
      <xsql:query null-indicator="yes" >
        SELECT * FROM TC_HL7_SEG WHERE SEGMENT_CODE LIKE '{@code}%'
      </xsql:query>
    </page> .
    And here's what it would look like using real bind variables:
    <page connection="UTD4" xmlns:xsql="urn:oracle-xsql">
      <xsql:query null-indicator="yes" bind-params="code">
        SELECT * FROM TC_HL7_SEG WHERE SEGMENT_CODE LIKE ?||'%'
      </xsql:query>
    </page> .
    Using real bind variables allows the database to avoid reparsing the SQL statement everytime, which improves performance.
    Steve Muench
    JDeveloper/BC4J Development Team
    Author, Building Oracle XML Applications

  • Can I use a VO with Bind Params as an LOV?

    And if so, how can I specify the values to be used for the Bind Params at runtime?
    I am trying to think outside the box for dependent dynamic lists...
    Thanks.

    A little more info...
    I have tried adding an Action to my pageDef Bindings:
    <action IterBinding="DelegationsWithScopeTypeParamIterator"
    id="ExecuteWithParams1"
    InstanceName="EVCServiceDataControl.DelegationsWithScopeTypeParam"
    DataControl="EVCServiceDataControl" RequiresUpdateModel="true"
    Action="95">
    <NamedData NDName="ScopeTypeIdVar" NDValue="${userState.currentType}"
    NDType="oracle.jbo.domain.Number"/>
    <NamedData NDName="CurUserIdVar"
    NDValue="${sessionScope.userState.currentUserId}"
    NDType="oracle.jbo.domain.Number"/>
    </action>
    And an invokeAction to the Executables:
    <invokeAction id="ReloadScopeList" Binds="ExecuteWithParams1"
    Refresh="prepareModel" RefreshCondition="true"/>
    Now, how do I get ReloadScopeList to do its thing when a user selects a value in one selectOneChoice list so the second selectOneChoice list's iterator will be updated? Am I crazy?
    Thanks,.

  • Tester: tests a View with bind params?

    Test a View with the right click on the AM, Test, that has
    bind params?
    After much searching the Help and this forum, I can't find the
    post that explained how to wrap another View to front end a
    SQLView/View with bind params.
    Thanks, curt

    Just as I posted this I thought of the search string that worked.
    I searched on "bind param" and oddly only one page of hits and
    the explanation on how to create a ViewHolder and ViewLink to
    front end a View with bind params and then to test it is in
    this message:
    Re: Getting message failed to load the following objects when opening any fmb
    curt

  • ADF BC: modifying VO bind params before executing the query

    Hi gang
    I've a use case in ADF BC where I need to modify View Object bind parameters (eg. convert strings to uppercase) entered by users to change the result of the underlying VO query, and show the modified bind parameters to the user after the query.
    Normally I would do this in the VO query by modifying the query where clause with the appropriate SQL. However this method is not applicable in this specific use case as the user doesn't get to see the modified bind parameters as a result.
    I've thought about a few options including:
    1) Generating the bind parameter accessors for the ViewObjectImpl and overriding the bind parameter setters to convert all string values to uppercase. This wasn't suitable as it looks like ADF Faces RC doesn't make use of the accessors via the default ADF bindings.
    2) Overriding the applyViewCriteria() method in the ViewObjectImpl - which however isn't appropriate as it applies to search fields entered as view criteria, not bind parameters.
    3) Overriding the executeQueryForCollection() method in the ViewObjectImpl - I thought I was on a winner here as I could retrieve the bind parameters via a call to getNamedWhereClauseParams(), modify the bind params and then call setNamedWhereClauseParams() to set them back. Unfortunately to really set the params I then need to call executeQuery() inside executeQueryForCollection() which puts the VO in a loop. You can see my sample code below:
    @Override
    protected void executeQueryForCollection(Object queryCollection,
                                             Object[] bindParams,
                                             int noUserParams) {
      AttributeList bindParamList = getNamedWhereClauseParams();
      String[] bindParamNames = bindParamList.getAttributeNames();
      Object[] bindParamValues = bindParamList.getAttributeValues();
      boolean valueChange = false;
      if (bindParamNames != null && bindParamValues != null) {
        String bindParamName = null;
        Object bindParamValue = null;
        for (int i = 0, j = bindParamNames.length; i < j; i++) {
          bindParamName = bindParamNames;
    bindParamValue = bindParamValues[i];
    if (bindParamName != null && !bindParamName.equals("")) {
    if (bindParamValue instanceof String) {
    if (bindParamValue != null && !bindParamValue.equals("")) {
    bindParamList.setAttribute(bindParamName, (Object)((String)bindParamValue).toUpperCase());
    valueChange = true;
    } // else do nothing; null String
    } // else do nothing; only interested in converting Strings to upper case
    } // else do nothing; bind parameter name is null
    } // else do nothing; bind parameter name or value list is null
    if (valueChange) {
    setNamedWhereClauseParams(bindParamList);
    // executeQuery(); // we can't do this; causes an infinite loop
    super.executeQueryForCollection(queryCollection, bindParams, noUserParams);
    I can think of a number of solutions/hacks in ADF Faces RC to get around this issue, but ideally I'd like to keep the solution in the model layer. Does anybody have a better idea of how I could do this? Your help appreciated.
    Thanks & regards,
    CM.
    PS. JDev 11g Boxer 5188: ADF BC + ADF Faces RC

    Hi Chris,
    have you tried modifying the passed-in bindParams argument to work around the need to call executeQuery()?
    That's what I would've done:
    I would have set the named where clause params (like you do) and after that I would have tried to get a new parameters Object[] back by calling ViewRowSetImpl.getParametersAsStorageType() and pass that to the super call.
    Sascha

  • How to use a bind variable in an IN clause

    I am trying to use a bind variable in an IN clause where the column is a varchar2 type. Something like:
    select *
    from test
    where test_column in (:bindVariable)I have tried assigning the bind variable comma separated strings (eg. test,test,test) and comma separated strings with quotes (eg. 'test','test','test'). Neither of these work. Does anyone know the correct way to do this?
    Thanks in advance.

    http://tkyte.blogspot.com/2006/06/varying-in-lists.html
    Presents many options.

  • XSQL ERROR with bind-params in ref-cursor-function

    Hi Steve
    I always get the error
    ORA-01006 bind variable does not exist
    when using a bind variable in a <xsql:ref-cursor-function> action element.
    when I replace the bind variable with a @ - parameter substitution, all works fine.
    My configuration:
    XSQL 1.0.4.1 on Win200Pro ,Apache + Jserv + DB from ORA 8.1.7 installation
    My Source
    <xsql:ref-cursor-function
    dbconn="ekat"
    eblike="%"
    list="a0"
    bind-params="eblike"
    include-schema="no"
    null-indicator="no"
    id-attribute=""
    fetch-size="500"
    >
    {@dbconn}o.ekatkategcv.open_cv_ebh ('{@list}', :1)
    </xsql:ref-cursor-function>
    ( dbconn selects my schema, not changed often, which contains package ekatkategcv with
    function open_cv_ebh returning a cursor)
    Any fix would be appreciated to avoid reparsing on each call.
    BTW, is it right, that a ref-cursor funtion is reparsed whenever the content of
    a parameter used with @ changes?
    Best regards
    H.Buschmann ([email protected])
    null

    I have tried it using ? instead of :1, this method works fine.
    I haven't tried the name method (:bindvar) yet.
    Until now, I only used xsl:query and xsql:ref-cursor-function, so I didn't check
    the other action handlers with bind variables like :1
    null

  • JDev11g : Problem with Binding param (viewcriteria)

    When I bind some variables (2 type number and 2 type date) to viewCriteria and start the web site I get very strange problem.
    The Binding param is almost random (I set on binding variables Binding position), and because of this I get constant SQL errors (Invalid type and so on).
    Some data from server log
    First start of server:
    [ pre]
    <strong>[8945]Binding null of type 12 for 1</strong>
    <strong>[8946] Binding null of type 12 for 2</strong>
    <strong>[8947] Binding param 3: 41</strong>
    <strong>[8948] Binding null of type 12 for 4</strong>
    <strong>[8949] Binding param 5: 148</strong>
    <strong>[8950] Binding param 6: 148</strong>
    <strong>[8951] Binding param 7: 148</strong>
    Second start of server:
    <strong>[9213] Binding null of type 12 for 1</strong>
    <strong>[9214] Binding null of type 12 for 2</strong>
    <strong>[9215] Binding null of type 12 for 3</strong>
    <strong>[9216] Binding param 4: 41</strong>
    <strong>[9217] Binding null of type 12 for 5</strong>
    <strong>[9218] Binding param 6: 148</strong>
    <strong>[9219] Binding param 7: 148</strong>
    <strong>[9220] Binding param 8: 148</strong>
    [ pre]
    And view criteria query looks like this :
    FROM_DATE (binded to variable fromDate_bind type DATE and binding position set to 1)
    TO_DATE (binded to variable toDate_bind type DATE and binding position set to 3)
    WORKER_ID (binded to variable worker_bind type NUMBER and binding position set to 2)
    CLASS (binded to variable class_bind type NUMBER and binding position set to 4)
    [ pre]( ( ( ( FROM_DATE &gt;= ? ) OR ( ? IS NULL ) ) AND (WORKER_ID = ? ) AND ( ( TO_DATE &lt;= ? ) OR ( ? IS NULL ) ) AND ( ( CLASS = ? ) OR ( ? IS NULL ) ) ) )
    This viewCriteria is shown on page as af:query (simple search form) and outputs results on af:table.
    Is there any way to solve this random parameter binding?
    Rok Kogov&scaron;ek

    check out the fileUpload article
    Using the File Upload Component
    http://developers.sun.com/prodtech/javatools/jscreator/learning/tutorials/2/file_upload.html

  • JHS detects changes in query bind param when there is none

    I have a view object with a query bind parameter using #{param.id} in the JHS app definition. The page has a hidden field with the same name as param.id to handle reposts. The page layout is master-detail with the VO using the query bind param as the master.
    The problem is that every time navigation to the detail occurs, the query on the master is rerun. In the output, I see "Value of bind param id has changed, old value=3110 new value=3110." The same thing is true with table-form layout.

    Bump. This is a big issue for us. The view object is being requeried everytime naviagation between rows or to the detail occurs. What are the possible causes of this? The output we are seeing is below.
    10:28:40 DEBUG (JhsNavigationHandlerImpl) -Executing checkRoles
    07/03/13 10:28:40 [778] **** refreshControl() for BindingContainer :CadetGroupsObjPageDef
    07/03/13 10:28:40 [779] DCUtil, returning:oracle.adf.model.binding.DCDataControl$MethodResultsMap, for methodResults
    07/03/13 10:28:40 [780] Invoke method Action:999
    07/03/13 10:28:40 [781] DCInvokeMethod:Invoking ABCMenuAppModuleDataControl.dataProvider.applyBindParams()
    10:28:40 DEBUG (JhsApplicationModuleImpl) -Executing applyBindParams for CadetGroupsViewObj
    10:28:40 DEBUG (JhsApplicationModuleImpl) -ViewObject CadetGroupsViewObj: value of bind param stfPid has changed: old value=3110 ,new value=3110
    10:28:40 DEBUG (JhsApplicationModuleImpl) -ViewObject CadetGroupsViewObj: executing query, bind parameter values have changed
    07/03/13 10:28:40 [782] Column count: 16

  • Loosing bind params

    Hi,
    We are having a problem with our application that we loose our bind parameters after a while.
    There is a view object that has a bind param called p_id. Which we set by using setp_id and perform executyQuery inside coding. If we leave the page alone for around 1 hour and try to load it again, we get an empty page back and looking at the bc4j logging the bindings try to do a executeQuery and bind "null" to p_id. If we open up another page which has a apply bindparam we get the correct p_id again.
    Has anyone any idea what the problem might be?
    Do we have to add an applyBindparam binding/invoke to each page?
    Is this caused by a difference between web session timeout and AM timeout? (web session has a 180 min timeout and AM has default setting)
    Or do we need to call a pagebinding in order to set bind variables iso binding it with code and executing it manualy.

    Nobody can tell without knowledge of your jdev version and the technology you are using for UI, middle tier and db.
    There have been reports in early 10.3.1 versions going in the direction, that bind parameters are not stored is the application module is passivated.
    The best thing to do is to test the app without application module pooling. This pooling can be turned off in the configuration of the application module. After turning it of each call to the application module gets passivated and activated again, simulating a timeout for every request.
    Timo

  • BIND-PARAMS HELP PLEASE IN XSQL

    Hello All,
    I have 3 tables these are track, album and a join table called albumTrack I need to use bind-params to link album and track up with the join table so that when i select an album I can view all the tracks associated with that album. Here is my XSQL page:
    <xsql:query  rowset-element="albums" row-element="album">
    SELECT
    dbalbumid AS albumid,
    dbalbumname AS albumname
    FROM
    album
    </xsql:query>
    <xsql:query  rowset-element="albumTracks" row-element="albumTrack">
    SELECT
    dbalbumid AS albumId,
    dbalbumtrackid AS albumTrackId
    FROM
    albumTrack
    </xsql:query>
    <xsql:query  rowset-element="tracks" row-element="track">
    SELECT
    dbtrackid AS trackid,
    dbtrackname AS trackname
    FROM
    track
    </xsql:query>Edited by: user10711723 on 13-Jan-2009 11:22

    solved.

  • Need to have more info about the latest patch on Oracle 10g Release 2

    Please this is the follwing answer that was given to explain the purpose of patching the latest release of Oracle 10g release 2.
    We are applying the patch to the 32bit environment to resolve memory errors.
    This patch should be applied to the 64bit environments too as to maintain consistency in our database versions
    Personaly I don't believe the response is accurate to patch the database.
    Does someone can tell me where to find more information about the latest path of Oracle 10g release 2?
    Thanks a lot

    You can find more information about a patchset by going over the readme document associated with the patch. As such, it is not exactly clear what kind of information you are looking for.
    Login into Metalink=>Patches&Updates=>Simple Search=>
    Product or Family=> RDBMS
    Select your OS
    if will your a link to the readme file...
    Hope this helps
    Thanks
    Chandra

  • Using bind variable in dynamic where clause and concatenate with query

    Hi,
    In my procedure i am framing where clause dynamically with bind variable,When i am concatenate this with my sql query for REF CURSOR i got sql command not properly ended exception.
    Is it possible to pass values to the bind variable through the dynamic variable/value?
    Please advise
    Thanks in advance
    Siva
    IF in_applicationId IS NOT NULL THEN
              optional_where := optional_where || ' AND a.APPLICATION_ID like '||':e%';
              optional_using := ' in_appFuncGroup'||',in_currentUserID'||',in_appFuncGroup'||',in_queue_id'||',in_applicationId';
         END IF;
    My query is like this
    open Out_Main FOR SelectQuery USING optional_using

    Thanks for reply,
    In my procedure, i suppose to frame the where clause with bind dynamically according to the input parameters. so that i am framing the values of the bind variables also dynamically like this,
    Please advise...
    IF in_assignedAppFlag IS NOT NULL THEN
              IF in_assignedAppFlag = 'Y' THEN
                   optional_where := optional_where || ' AND b.ASSIGNED_TO = :b' ;
              optional_using := ' in_appFuncGroup'||',in_currentUserID';          
              ELSe
                   IF in_isSupervisor = 0 THEN
                        optional_where := optional_where || ' AND (b.ASSIGNED_TO = :b'||' OR b.ASSIGNED_TO = ''-1'' OR b.ASSIGNED_TO IS NULL)';
              optional_using := ' in_appFuncGroup'||',in_currentUserID';
                   END IF;
              END IF;
         ELSE
              IF in_isSupervisor = 0 THEN
                   optional_where := optional_where || ' AND (b.ASSIGNED_TO = :b'||' OR b.ASSIGNED_TO = ''-1'' OR b.ASSIGNED_TO IS NULL)';
                   optional_using := ' in_appFuncGroup'||',in_currentUserID';
              END IF;
         END IF;
         IF in_appFuncGroup IS NOT NULL THEN
              optional_where := optional_where || ' AND e.APP_FUNC_GROUP= :c';
              optional_using := ' in_appFuncGroup'||',in_currentUserID'||',in_appFuncGroup';
         END IF;
         IF in_queue_id IS NOT NULL THEN
              optional_where := optional_where || ' AND b.QUEUE_ID = :d';
              optional_using := ' in_appFuncGroup'||',in_currentUserID'||',in_appFuncGroup'||',in_queue_id';
         END IF;
         IF in_applicationId IS NOT NULL THEN
              optional_where := optional_where || ' AND a.APPLICATION_ID like '||':e%';
              optional_using := ' in_appFuncGroup'||',in_currentUserID'||',in_appFuncGroup'||',in_queue_id'||',in_applicationId';
         END IF;
         IF in_sourceCode IS NOT NULL THEN
              optional_where := optional_where || ' AND e.APP_SOURCE_CODE like '||':f%';
              optional_using := ' in_appFuncGroup'||',in_currentUserID'||',in_appFuncGroup'
              ||',in_queue_id'||',in_applicationId'||',in_sourceCode';
         END IF;
         IF in_logo IS NOT NULL THEN
              optional_where := optional_where || ' AND appProds.PRODUCT_TYPE like '||':g%';
              optional_using := ' in_appFuncGroup'||',in_currentUserID'||',in_appFuncGroup'
              ||',in_queue_id'||',in_applicationId'||',in_sourceCode'||',in_logo';
         END IF;
         IF in_firstName IS NOT NULL THEN
              optional_where := optional_where || ' AND upper(a.FIRST_NAME) like upper(:h%)';
              optional_using := ' in_appFuncGroup'||',in_currentUserID'||',in_appFuncGroup'
              ||',in_queue_id'||',in_applicationId'||',in_sourceCode'||',in_logo'||',in_firstName';
         END IF;
         IF in_surName IS NOT NULL THEN
              optional_where := optional_where || ' AND upper(a.SURNAME) like upper(:i%)';
              optional_using := ' in_appFuncGroup'||',in_currentUserID'||',in_appFuncGroup'
              ||',in_queue_id'||',in_applicationId'||',in_sourceCode'||',in_logo'||',in_firstName'||',in_surName';
         END IF;
         IF in_retreival_id IS NOT NULL THEN
              optional_where := optional_where || ' AND e.RETREIVAL_ID like :j%';
              optional_using := ' in_appFuncGroup'||',in_currentUserID'||',in_appFuncGroup'
              ||',in_queue_id'||',in_applicationId'||',in_sourceCode'||',in_logo'||',in_firstName'||',in_surName'||',in_retreival_id';
         END IF;

  • SQL select query having more than 1000 values in 'IN' clause of predicate.

    Hi,
    We are executing a select query from a table and showing it through a front end screen. When the count of values given in the 'IN' clause of predicate are exceeding 1000 , it is throwing error.
    eg. select * from Employees where emp.Id. in('111',123','121','3232',........1001 Ids)
    We are using Oracle version 10.2.0.
    Please suggest how to tackle such issue.
    Regards,
    Naveen Kumar.C.
    Edited by: Naveen Kumar C on Aug 30, 2008 10:01 PM

    Use a nested table:
    create or replace type numbertype
    as object
    (nr number(20,10) )
    create or replace type number_table
    as table of numbertype
    create or replace procedure tableselect
    ( p_numbers in number_table
    , p_ref_result out sys_refcursor)
    is
    begin
    open p_ref_result for
         select *
    {noformat}     from   employees
         ,        (select /*+ cardinality(tab 10) */ tab.nr
                   from   table(p_numbers) tab) tbnrs
         where id = tbnrs.nr;
    end;
    /{noformat}
    Using nested tables will reduce the amount of parsing because the sql statement uses binded variables! The cardinality hint causes Oracle to use the index on employees.id.

Maybe you are looking for

  • Emac with dead display

    Hi guys. I was lucky enough to pick up a triplet of eMacs yesterday. one of them is a 700mhz model that was working until the power button tore off. The other two I was told were 1ghz models, but the CD tray reports 1.25ghz (woohoo!!) The one is in p

  • How do I move clips from iMovie to a dvd

    I would like to make a DVD with clips that I have on iMovie.  How do I do so?  Also, how do I save in a way that it will be viewable on a PC? 

  • "Email for Nokia" Not Working Properly after Firmw...

    The "Email for Nokia – 10 Accounts" also called Nokia Messaging does not work after firmware upgrade.  I upgraded my E63 firmware from 400.21.13 to 410.21.10 (the latest).   After upgrade, I installed the Email software, ver 9.07(2), from Ovi store. 

  • Table of Machine hours in PP

    Hi all ,    I want to know in which table we can find the information related to machines used to produce an FG  or SFG ( Like how many mins the machine was run and what is the cost for that ) . I can find this in the Tcode KOB1 . But its giving me a

  • How to make a prog. Tree with Checkbox in JSF?

    I am facing prob. to how to dev. prog. which contain Tree with Checkbox . I want to use checkbox because whatever comes under any directory in Tree is selected if I select perticular folder from Tree? Can you guide me guys ? Ur help is needed to me.