Using "Oracle Positional" as Binding Style  for VO

Hi,
I have create a VO using Binding Style as "Oracle Positional". The query I have given as..
"select <All Column names> from Emp where deptNo = :1"
I have drag and drop the datacontrol related to this VO on JSP page.
Now the main issue is, "How to pass the default value for where condition when the page loads"?
can I add some thing in PageDef file to pass this data.
Thanks...
Sree

Two options:
1. You can define the default value at the view object layer in the binding parameter section.
2. If this is page specific then you can define it in the pagedef.xml file - look for the variableUsage tag under the executables section and set the DefaultValue property.

Similar Messages

  • Oracle.jbo.uicli.binding.JUCtrlActionBinding for method doesn't work

    I have a data control method called as listForums(). When i dropped this method on to a region it renders the data fine in af:selectOneChoice. But when the same method is dropped on to a simple jspx page it doesn't render the data.
    The difference in the console logs i see is that:
    In the case where it renders data it says:
    FINE: [103] DCUtil, returning:oracle.adfinternal.view.faces.model.binding.FacesCtrlActionBinding, for listForums
    But in the case where it doesn't render the data it says:
    FINE: [106] DCUtil, returning:oracle.jbo.uicli.binding.JUCtrlActionBinding, for listForums
    Can some one give me any tips on how to make this work on a simple jspx page?

    I have a test case with me.But I found out the issue. The problem is, in the old projects which we have created long time back, we never have migrated the web.xml file. Hence it was failing. I have migrated the web.xml now. So it started working fine. (Build JDEVADF_MAIN_GENERIC_070416.1022.4501).
    Thanx for the response.

  • Can I use oracle to build our webiste for free?

    Hi all~~
    I am a student in unversity and learning oracle database technology.
    Moreover,I hope to put it into practise.
    Therefore,I wanna use oracle and Java EE to build our own website for our club(an organization in our school) and we will deploy it to our own server.
    Can we use oracle without paying anything?
    Jason

    According to License Terms on OTN, you can has limited license to use the programs only for the purpose of developing, testing, prototyping and demonstrating your application, and not for any other purpose. So it sounds to me if this is purely for learning and internal use without commercial and production purpose, you don't have to pay. But Oracle and it's sales rep will have the final words. Better double check to confirm.
    http://www.oracle.com/technology/software/products/database/index.html
    LICENSE RIGHTS
    We grant you a nonexclusive, nontransferable limited license to use the programs only for the purpose of developing, testing, prototyping and demonstrating your application, and not for any other purpose. If you use the application you develop under this license for any internal data processing or for any commercial or production purposes, or you want to use the programs for any purpose other than as permitted under this agreement, you must obtain a production release version of the program by contacting us or an Oracle reseller to obtain the appropriate license. You acknowledge that we may not produce a production release version of the program and any development efforts undertaken by you are at your own risk. We may audit your use of the programs. Program documentation, if available, may accessed online at http://otn.oracle.com/docs.

  • Using Column Value in CSS Style for Column in Report

    I am trying to apply a CSS style (background color) to a column in a report based on another column.
    So for the Column attributes for a specific column, I would like to be able to add this to the 'CSS Style' Field under the group, "Column Formatting":
    background-color:#BKG_COLOR#;
    It doesn't seem to be taking my column value, which is #daf2ea
    In the CSS Style Field, if I change it to: background-color:#daf2ea - then it works.
    So it doesn't seem to take my column value of #BKG_COLOR" in the CSS Style field.
    Any ideas? Do I need to use the 'HTML Expression' field instead, and how would I do that?
    Thanks,
    John

    Hi,
    that's correct, custom report templates will do.
    I find them sometimes quite limited, though. And I always ask myself "how would I do it without APEX", because there's often a lean jQuery solution that affords less coding.
    If you employ a so called "marker class" that depends on your colour value, you could begin like in the previous answer and enter the follwing into HTML Expression:
    &lt;span class="#BKG_CLASS#"&gt;#THE_COLUMN_I_WANT_TO_SHOW#&lt;/span&gt;
    That means you would not query a plain color, but some name that can act as a CSS marker, like
    select THE_COLUMN_I_WANT_TO_SHOW
          , case when THE_COLUMN_I_WANT_TO_SHOW > 100 then 'hotColor' else 'coldColor' end as BKG_CLASS
      from my_tableIn the page's Function and Global Variable Declaration, you'd enter
    function colorMyReport () {
      apex.jQuery('.hotColor').closest('td').css('background-color','#FAA');
    }And under Execute when Page Loads, you enter:
    colorMyReport();There's only one challenge, of course, when the report is paged via AJAX, because the script would only run once (on the first page shown).
    But if this is a solution for you, I'd be pleased to show you how to overcome this. Just let me know.
    Hope there is no typo in my typing, because I have to catch my train now :-)
    Bye!

  • Using Oracle SAP Adapter and IBSE for inbound IDOCs

    I have been able to successfully use the Oracle SAP Adapter (e.g., IWAY) using the IWAY Business Services Engine (IBSE) to call a BAPI and have information returned. This use case is well documented and seems to be reliable.
    However, I have had difficulty finding any examples where IBSE is used with IDOCS. In my case, I would like to have SAP send an IDOC and receive this IDOC in a Fusion 11g environment. I see conflicting statements in the document. On one hand, Section 3 of this document
    http://download.oracle.com/docs/cd/E15523_01/doc.1111/e17057/config.htm#BABBGAAH
    States "Events are not applicable when using a BSE configuration."
    On the other hand, I see lots of documentation that says that you need to configure an Event in order for the IDOC to be sent to the proper destination. IBSE gives the ability to define events for IDOCs but the events are limited to either RMI or JMS. I have looked at the format of the JMS message and it looks extremely difficult to setup.
    Has anyone done this before?

    Let me try what ever I can to answer.
    Loss of IDOCS should not happen. Are you starting the channels in iWay test tools while the JCA adapter is also running?. That should not be the case. iWay Test tools is only for design time purpose. It is not required for runtime. ie. Create channels and test the IDOCS being received. After that stop the channel and start running the server.
    I suspect that starting channel in iWay test tools and JCA adapter/BPEL simultaneously will definitely result in IDOCS loss. Some of the IDOCS will come to iWay test tool while others will go to JCA/BPEL.
    Regarding 2, lets us discuss this after this loss of messages is solved.
    "Another issue that we have with the JCA approach is the requirement to have have a separate channel and a separate program ID for every IDOC. In our SAP system, we have thousands of IDOCS so having to setup a different channel and program ID for each one is going to be a difficult task".Yes. Initial versions of adapter used to support receiving all idocs on same channel. In your case MATMAS05/IORDER01 are received on same programID and customers used has logic to identify what idoc was coming. It was observed that complexity of the application increases exponentially with increased idocs and the debugging effort.And also the interface is not clean. That is the JCA end point cannot be assocaited with a specific WSDL so you will not what you will receive and of what type. To ease this, later version of adapter supported this feature that each idoc type is assocaited with a specific program ID. MATAS05--PID1, IORDER01--PID2. Adapter will ignore if MATMAS05 is sent on PID2.
    In OSB we have concept of AnyXML service but I doubt if BPEL has such concept. If I remember OSB smart connect supported your exact use-case, but in later version it was decided to discontinue AnyXML inbounds.
    Are you really planning to use hundreds of IDOCS on same PID?. Did you think of debugging complexity in such application? If you really think this need to be supported, please raise an enhancement request with Support. Product management will review your request for further action.
    Thanks
    Manoj

  • Using Oracle's Parallel Server for synchronizing databases with different tables

    Hello,
    I have a problem and I was searching through the Oracle documentation.
    Then I mentioned the Oracle's Parallel Server (OPS) feature.
    The problem I want to fix is the following:
    I want to make a copy of a database. Subsequently I want to make changes to the copy of the original database. (possible changes could be extra columns).
    Now I want to synchronize the data of both databases...
    Is it possible to use Oracle's Parallel Server feature for this task?
    Greets,
    Harm

    Hello,
    I have a problem and I was searching through the Oracle documentation.
    Then I mentioned the Oracle's Parallel Server (OPS) feature.
    The problem I want to fix is the following:
    I want to make a copy of a database. Subsequently I want to make changes to the copy of the original database. (possible changes could be extra columns).
    Now I want to synchronize the data of both databases...
    Is it possible to use Oracle's Parallel Server feature for this task?
    Greets,
    Harm

  • How to pass pageFlowScope variable value as bind variable for VO

    Hi,
    I have one fixed lov (not based on datasource), if i select any value in that lov i want to pass this value to a pageFlowScope variable.
    After this i want to use this value as bind variable for VO. whenever the vo executes thereafter this bind variable should filter that vo results.
    My jdev version: 11.1.0.0
    Thanks in advance,
    SAN

    san-717,
    can you elaborate on the use case instead of the implementation you don't get done? I understand you have data displayed in a tree: so lets assume the tree structure is Locations, Departments and Employees according to the Oracle HR sample schema.
    1. What is the LOV supposed to do ?
    2. Where is the LOV located ?
    3. What values does the LOV show ?
    4. Is the LOV a select choice component or a real LOV (with search dialog)
    5. Where is the bind variable used ?
    To me it sounds like you want to filter the tree data based on the select choice value. However, you wont do this by passing the bind parameter to all View Objects involved as they may not have the attribute in their query. So your use case is important to answer the question
    Frank

  • Custom Workflow using Oracle Workflow in ContentDB

    Hi,
    Could we use custom workflow which is made using Oracle Workflow instead of BPEL.
    Regards,
    Yulisar

    Having registered custom workflows for Content DB via Enterprise Manager, potentially you can use any tool capable of dequeuing/enqueing messages from the IFS_BPEL_OUT/IFS_BPEL_IN advanced queues as part of a custom workflow process.
    By default, we assume you are using Oracle BPEL PM with its Advanced Queue adapater to process the queue messages. However, there is nothing stopping using Oracle Workflow or any tool for that matter.
    HOWEVER!!! Warning!!! There is a high probability that Content DB will drop the bundled Oracle Worflow installation in the near future. What this means, is that you should consider installing/configure/patching your own separate Oracle Workflow installation and not rely on the bundled Content DB solution which is used internally for Serial and Parallel Approval workflows.
    thanks,
    Matt.

  • Oracle.jbo.uicli.binding.JUIteratorBinding cannot be cast to oracle.adf.

    HI ,
    I'm using ADF 11g,
    I'm working on individual work space. i have used oracle.adf.model.binding.DCControlBinding in my bean class and working fine .Now one day before i have taken svn version repository project and started working .I made simple jspx with adf table and tool bar button such as Add. When i fire add button i'm calling a method in bean class.
    public String createRecord() {
    // Add event code here... bank_add
    System.out.println("-- create record --");
    BindingContainer bindings2 = ADFUtils.getBindingContainer();
    DCControlBinding dcc = (DCControlBinding)bindings2.get("XbtBankSettlementVOIterator");
    return "banksettlement_add";
    surprisingly i got this error.when my fellow colleague is using same svn repository project and using oracle.adf.model.binding.DCControlBinding it is working fine.
    but why i'm getting this error below.i have followed the same steps to create View Object and Entity Object as previous .
    <ActionListenerImpl><processAction> java.lang.ClassCastException: oracle.jbo.uicli.binding.JUIteratorBinding cannot be cast to oracle.adf.model.binding.DCControlBinding
    javax.faces.el.EvaluationException: java.lang.ClassCastException: oracle.jbo.uicli.binding.JUIteratorBinding cannot be cast to oracle.adf.model.binding.DCControlBinding
         at org.apache.myfaces.trinidad.component.MethodExpressionMethodBinding.invoke(MethodExpressionMethodBinding.java:51)
         at com.sun.faces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:102)
         at org.apache.myfaces.trinidad.component.UIXCommand.broadcast(UIXCommand.java:190)
         at oracle.adf.view.rich.component.fragment.UIXRegion.broadcast(UIXRegion.java:148)
         at oracle.adf.view.rich.component.fragment.ContextSwitchingComponent$1.run(ContextSwitchingComponent.java:90)
         at oracle.adf.view.rich.component.fragment.ContextSwitchingComponent._processPhase(ContextSwitchingComponent.java:309)
         at oracle.adf.view.rich.component.fragment.ContextSwitchingComponent.broadcast(ContextSwitchingComponent.java:94)
         at oracle.adf.view.rich.component.fragment.UIXInclude.broadcast(UIXInclude.java:102)
         at oracle.adf.view.rich.component.fragment.ContextSwitchingComponent$1.run(ContextSwitchingComponent.java:90)
         at oracle.adf.view.rich.component.fragment.ContextSwitchingComponent._processPhase(ContextSwitchingComponent.java:309)
         at oracle.adf.view.rich.component.fragment.ContextSwitchingComponent.broadcast(ContextSwitchingComponent.java:94)
         at oracle.adf.view.rich.component.fragment.UIXInclude.broadcast(UIXInclude.java:96)
         at oracle.adfinternal.view.faces.lifecycle.LifecycleImpl.broadcastEvents(LifecycleImpl.java:812)
         at oracle.adfinternal.view.faces.lifecycle.LifecycleImpl._executePhase(LifecycleImpl.java:292)
         at oracle.adfinternal.view.faces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:177)
         at javax.faces.webapp.FacesServlet.service(FacesServlet.java:265)
         at weblogic.servlet.internal.StubSecurityHelper$ServletServiceAction.run(StubSecurityHelper.java:227)
         at weblogic.servlet.internal.StubSecurityHelper.invokeServlet(StubSecurityHelper.java:125)
         at weblogic.servlet.internal.ServletStubImpl.execute(ServletStubImpl.java:292)
         at weblogic.servlet.internal.TailFilter.doFilter(TailFilter.java:26)
         at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)
         at oracle.adf.model.servlet.ADFBindingFilter.doFilter(ADFBindingFilter.java:191)
         at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)
         at oracle.adfinternal.view.faces.webapp.rich.RegistrationFilter.doFilter(RegistrationFilter.java:97)
         at org.apache.myfaces.trinidadinternal.webapp.TrinidadFilterImpl$FilterListChain.doFilter(TrinidadFilterImpl.java:420)
         at oracle.adfinternal.view.faces.activedata.AdsFilter.doFilter(AdsFilter.java:60)
         at org.apache.myfaces.trinidadinternal.webapp.TrinidadFilterImpl$FilterListChain.doFilter(TrinidadFilterImpl.java:420)
         at org.apache.myfaces.trinidadinternal.webapp.TrinidadFilterImpl._doFilterImpl(TrinidadFilterImpl.java:247)
         at org.apache.myfaces.trinidadinternal.webapp.TrinidadFilterImpl.doFilter(TrinidadFilterImpl.java:157)
         at org.apache.myfaces.trinidad.webapp.TrinidadFilter.doFilter(TrinidadFilter.java:92)
         at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)
         at oracle.security.jps.ee.http.JpsAbsFilter$1.run(JpsAbsFilter.java:94)
         at java.security.AccessController.doPrivileged(Native Method)
         at oracle.security.jps.util.JpsSubject.doAsPrivileged(JpsSubject.java:313)
         at oracle.security.jps.ee.util.JpsPlatformUtil.runJaasMode(JpsPlatformUtil.java:413)
         at oracle.security.jps.ee.http.JpsAbsFilter.doFilter(JpsAbsFilter.java:138)
         at oracle.security.jps.ee.http.JpsFilter.doFilter(JpsFilter.java:70)
         at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)
         at oracle.adf.library.webapp.LibraryFilter.doFilter(LibraryFilter.java:159)
         at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)
         at oracle.dms.wls.DMSServletFilter.doFilter(DMSServletFilter.java:326)
         at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)
         at weblogic.servlet.internal.RequestEventsFilter.doFilter(RequestEventsFilter.java:27)
         at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)
         at weblogic.servlet.internal.WebAppServletContext$ServletInvocationAction.run(WebAppServletContext.java:3592)
         at weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:321)
         at weblogic.security.service.SecurityManager.runAs(SecurityManager.java:121)
         at weblogic.servlet.internal.WebAppServletContext.securedExecute(WebAppServletContext.java:2202)
         at weblogic.servlet.internal.WebAppServletContext.execute(WebAppServletContext.java:2108)
         at weblogic.servlet.internal.ServletRequestImpl.run(ServletRequestImpl.java:1432)
         at weblogic.work.ExecuteThread.execute(ExecuteThread.java:201)
         at weblogic.work.ExecuteThread.run(ExecuteThread.java:173)
    Caused by: java.lang.ClassCastException: oracle.jbo.uicli.binding.JUIteratorBinding cannot be cast to oracle.adf.model.binding.DCControlBinding
         at com.agile.xb.view.managed.BankSettlementDtlBean.createRecord(BankSettlementDtlBean.java:32)
         at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
         at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
         at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
         at java.lang.reflect.Method.invoke(Method.java:597)
         at com.sun.el.parser.AstValue.invoke(AstValue.java:157)
         at com.sun.el.MethodExpressionImpl.invoke(MethodExpressionImpl.java:283)
         at org.apache.myfaces.trinidad.component.MethodExpressionMethodBinding.invoke(MethodExpressionMethodBinding.java:46)
         ... 51 more
    thanks in advance

    Hi Frank,
    I know that JUIteratorBinding is taking ,but how can i change and where could i find . I have import operation binding in my bean and creation of VO and EO object time as i did noraml way .
    sorry can i get some more information.
    thanks in advance .

  • Newbie in using Oracle...

    Hi everybody,
    I am new here and new in using Oracle database or other tools, can you tell me what do I need to install in chronological order in order to learn how to use Oracle database as back-end for Visual Studio .Net 2003/2005/2008 projects?? Also, any suggestions on very useful books to learning to use Oracle (PL/SQL syntax), preferably showing equivalent of MS SQL syntax to Oracle SQL syntax and other things.
    List of possible downloads:
    1. Oracle Database 10g Express edition(Western European)
    2. Oracle Database 10g Express Edition (Universal)
    3. Oracle Database 10g Express Client
    Which of these 3 I need to download?
    1. Oracle Developer Tools for Visual Studio .NET with Oracle 10g Release 2
    2. ODAC 10.2.0.2.21
    3. Oracle 10g Release 2 ODAC 10.2.0.2.21
    4. Oracle Developer Tools for Visual Studio .NET (for Oracle Database 10g Express Edition)
    5. Oracle 10g ODAC 10.1.0.4.0
    6. Oracle Developer Tools for Visual Studio .NET 10.1.0.4
    7. Oracle 9i Release 2 ODAC 9.2.0.7.0
    Which of these above I needed for Visual Studio .Net 2003/2005/2008 (Windows App, ASP.Net, Web Service and .Net Remoting)??
    Thanks.
    Dennis

    Hi,
    check below link. It will surely help you solve your problem:
    http://www.dannorris.com/2007/06/13/oracle-http-server-apache-rotatelogs-configuration/
    Regards

  • Has anyone successfully used Oracle EM as a Monitoring Solution??

    Hi All,
    This might be a wrong place to post ;) but anyways. My question is can we use Oracle EM as a Monitoring Solution? If so has anyone successfully used it?
    I have used Oracle EM over the years for mostly managing Databases. Eventually with the Middleware Support I have tried to use it to monitor Middleware Servers, earlier OC4J and recently WebLogic Servers. I however find that most people when talk about EM they think of it as a Business Transaction Monitoring Solution. (Lets keep BTM out for a while I know about that plugin but it is another full set of questions)
    Mostly I get questions as to can we "drill down the transactions" and see who initiated it and "what is being processed at this moment". Here transaction means Business Transaction as opposed "this thread is executing this particular piece of code". People want to know this piece of code is being executed "for Purchase Order XYZ" as opposed to just knowing that purchase order is being processed. If you know what i mean.
    No doubt OEM is great tool for an Admin but does it really sell itself as a monitoring solution? I have not seen a successful implementation so far with OEM being a central monitoring solution. If anyone has any experiences to share it would be great.

    I tried to look at that option. It is available only for the Database. I was looking something more towards say the web Services hosted or the Web Applications hosted on Weblogic instances. Can we find say the Web Service call which had the Purchase Order XYZ in its request, etc.

  • Using Oracle with Unix Cron

    Folks, hows everyone?.
    I am trying to go beyond SQL*Plus queries and teach myself some automation. Turned out to be a litle challenging. Can some one educate me on how to finish this task:
    I wish to automate the following report with crontab: pull data from HR account in Oracle and email it to [email protected] everyday at 6am.
    So, first, i wrote the following script, myqueryscript.sql, containing the query:
    spool /home/myname/myautoreport
    select * from hr;
    exit;
    /home/myname is my unix path and myautoreport directory to store a copy of results.
    Second, i wrote the following shell script, myshellscript, to execute myqueryscript.sql:
    /home/myname/sqlplus hr/psswd @/home/myname/myqueryscript
    third, I wrote the following crontab, mycronscript, to run the shell script:
    00 06 * * * "/home/myname/myshellscript"
    Finally, i submitted to crontab as:
    crontab mycronscript
    I didnt work. Am i missing something?.
    pls note: i am not the root in unix.
    Thanks,
    -a

    > Would you recommend this book on the basis of its contents table or any other
    books on the subject?
    Sorry - I'm not familiar with that author or that book. The most valuable Oracle "books" in my opinion are found at http://tahiti.oracle.com - the complete sets of all Oracle manuals from 8i to 10G.
    Many authors seem to only regurgitate Oracle manuals. The only Oracle book I've bought and considered as a worth every single cent, is Tom Kyte's Oracle Expert one-on-one.
    This goes into the very fundamental concepts of how to use Oracle correctly. It is a real eye opener.
    I am new to automation and wish to study it.What aspects of automation? It covers a very broad range of topics.
    Does automation in the way you described it, i.e. DBMS_JOB, depend on PL/SQL?Extensively. PL/SQL is a formal procedural language. It is as capable as Pascal, C or Java. Many seem to think in terms of PL/SQL as SQL plus some basic programming control structures. PL/SQL is not SQL. These are two different very languages.
    What makes it unique are:
    - it is a server side language running inside the Oracle database
    - it integrates so tightly with SQL that you can write SQL language statements in PL/SQL as if these are native to PL/SQL (which leads to the confusion thinking that PL/SQL is SQL)
    99% of all Oracle related code I write is PL/SQL. There is very little that you cannot do using PL/SQL. And Oracle is not just a capable database tier, it is just as capable as an application tier.
    When using Oracle, there is no need for a separate application tier like Weblogic, JBoss, etc. PL/SQL is in fact a lot more capable language for the application tier than Java or .NET.
    Simple example. One of the automation processes we have is to supply another system with delta changes from one of our databases. They wanted it in XML. They wanted it FTP'ed to their server. 100% of the code written for this is PL/SQL. From creating XML CLOBs in the database, to using FTP to transfer the contents of these CLOBs to their FTP server. With an APEX (Oracle Application Express) web application (also entirely PL/SQL) that provides for maintenance and administration of this automation.
    With less moving parts (not dealing with external processes and additional programming languages), Oracle PL/SQL applications are a lot quicker to develop, a lot easier to maintain, performant (it is very close to the data), and more robust.
    PL/SQL is a very critical core component in any automation and any application that uses the Oracle database.

  • How to use JDBC Positional Binding Style & ExecuteWithParams?

    Can anyone provide any help here including any documentation on how to configure this (I've checked online help and the developer guide.)
    When defining multiple Bind Position variables on a View Object (using sql statement binding style: JDBC Positional), should I defined multiple bind variable names? Otherwise, if I don't, when I use ExecuteWithParams operation to create the data control, only one input variable field is displayed. I can get a single bind position variable to work, but am struggling on how to configure / get multiple bind position variables to work with ExecuteWithParams.
    Here's my current configuration:
    1. Define View Object with two JDBC Positional Binding Parameters
    -- Bind Variables: name=parm1 (???should I define a second bind variable name???)
    -- Bind Positions = 0,1
    -- SQL Statement add another position var in where clause: "match (zip) against (CONCAT(?,'*') IN BOOLEAN MODE) and "match (name) against (CONCAT(?,'*') IN BOOLEAN MODE)
    2. On a JSF page, drag ExecuteWithParams operation from data control onto the JSF page. If I have defined only one bind variable name, only one input field is displayed (and one field label that I defined for that bind variable), but I need two input fields - one for each bind position variable. How do I set this up?
    Back-end Database is MySQL 5.0.1 which is why I am using binding stye JDBC positional.
    Thanks, Tom
    Message was edited by:
    javaX

    I did some more testing and the problem is that the queries work with one bind position variable but not with two. I created two simple view objects off of the same entity object to test:
    #1 - ViewObject with one bind position variable - where clause: where id > ?
    #2 - ViewObject with two bind position variables - where clause: where id > ? and id < ?
    I created two separate .jspx pages, view1.jspx (one input field) and view2.jspx (two input fields), for each view object by dragging ExecuteWithParams operation onto the JSF page.
    The .jspx page with one input field works (returns result sets.) The view2.jspx page with two input fields does not work - the query does not return any result sets (no errors produced, it just does not return any rows) - I've tested my query outside of jdeveloper and it works fine. I also tried switching my inputs to make sure I did not have an illogical query (i.e., id >100 and id< 1).
    Is there anything different / extra I need to do to use two bind position variables?
    I'm STUCK HERE.
    Everything in this simple test was identical except for using 2 input variables versus 1.
    Technology stack is: jdeveloper 10.1.3, jsf/ADF BC, mySQL 5.01
    Since I now understand what the problem is better, I'm going to re-post this as a new topic that more appropriately describes the problem, "Queries not working with multiple bind position variables?"
    Message was edited by:
    javaX

  • Why View Object Editor only allow "JDBC Positional" binding style?

    HI, I want to implement the following screencast tutorial: http://www.oracle.com/technology/products/jdev/tips/muench/screencasts/threesearchpages/threesearchforms_partthree.html?_template=/ocom/technology/content/print
    but I can't put the necesary "Oracle Named" binding style to create a sql statement with named bind variables like parametes. JDev 10.1.3.2 only allow JDBC Positional and I can't follow the above example.
    Regards.
    Alberto

    Hi,
    I guess that you are using a standard SQL Flavor and Type map.
    If you want to use these Oracle's JDBC features, you have to use Oracle SQL Flavor.
    (and you can use the Oracle Named" binding style in Jdev 10.1.3)
    Bye,
    Christophe

  • Looking for some help with using Oracle stored procedures in vb2010

    First off thank you to whoever lends me a hand with my problem. A little background first I am in a software development class and we are currently building our program using VB (I have no experience in this), and Oracle(currently in a Oracle class so I know how to use Oracle itself just not with VB).
    I am using vb2010 express edition if that helps. Currently I have a stored procedure that takes a 4char "ID" that returns a position (ie, salesperson,manager ect). I want to use the position returned to determine what vb form is displayed (this is acting as a login as you dont want a salesperson accessing the accountants page for payroll ect).
    Here is the code I have currently on the login page of my VB form
    Imports Oracle.DataAccess.Client
    Imports Oracle.DataAccess.Types
    Public Class Login
    Dim conn As New OracleConnection
    Private Sub empID_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles empID.Click
    End Sub
    Private Sub LoginBtn_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles LoginBtn.Click
    conn.ConnectionString = "User ID = Auto" & _
    ";Password = ********" & _
    ";Data Source = XE"
    conn.Open()
    Dim sq1 As String = "Return_Position" 'name of procedure
    Dim cmd As New OracleCommand(sq1, conn)
    cmd.CommandType = CommandType.StoredProcedure
    cmd.Parameters.Add(New OracleParameter("I_EmpID", OracleDbType.Char, 4)).Value = Emp_ID.Text
    Dim dataReader As OracleDataReader = cmd.ExecuteReader
    dataReader.Read()
    Dim position As New ListBox
    position.Items.Add(dataReader.GetString(0)) 'were I am getting an error, I also tried using the dataReader.getstring(0) to store its value in a string but its a no go
    If position.FindStringExact("MANAGER") = "MANAGER" Then
    Me.Hide()
    Dim CallMenu As New Menu()
    CallMenu.ShowDialog()
    End If
    LoginBtn.Enabled = False
    End Sub
    I have read the oracle.net developer guide for using oracle in vb2010 and have successfully gotten through the document however they never use a stored procedure, since the teacher wants this program to user a layered architecture I cannot directly store sql queries like the document does, thus the reason I want to use stored procedures.
    This is getting frustrating getting stuck with this having no background in VB, I could easily do this in c++ using file i/o even through it would be a pain in the rear....

    Hello,
    I am calling Oracle 11g stored procedures from VB.Net 2010. Here is a code sample (based on your code) you should be able to successfully implement in your application.
    Please note that you may have to modify your stored procedure to include an OUT parameter (the employee position) if it doesn't have it yet.
    Private Sub LoginBtn_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles LoginBtn.Click
    Dim sProcedureName As String = "Return_Position" 'name of stored procedure
    Dim ORConn as OracleConnection, sConn as String
    Dim sPosition as String, sDataSource as String, sSchema as String, sPWD as String
    Dim cmd As OracleCommand
    'please provide below sDataSource, sSchema and sPWD in order to connect to your Oracle DB
    sConn = "Data Source=" & sDataSource & ";User Id=" & sSchema & ";Password=" & sPWD & ";"
    ORConn = New OracleConnection(sConn)
    ORConn.Open()
    cmd = New OracleCommand(sProcedureName, ORConn)
    With cmd
    .CommandType = Data.CommandType.StoredProcedure
    'input parameter in your stored procedure is EmpId
    .Parameters.Add("EmpID", OracleDbType.Varchar2).Value = Emp_ID.Text
    .Parameters.Item("EmpID").Direction = ParameterDirection.Input
    'output parameter in your stored procedure is Emp_Position
    .Parameters.Add("Emp_Position", OracleDbType.Varchar2).Direction = ParameterDirection.Output
    .Parameters.Item("Emp_Position").Size = 50 'max number of characters for employee position
    Try
    .ExecuteNonQuery()
    Catch ex As Exception
    MsgBox(ex.Message)
    Exit sub
    End Try
    End With
    sPosition = cmd.Parameters.Item("Emp_Position").Value.ToString
    'close Oracle command
    If Not Cmd Is Nothing Then Cmd.Dispose()
    Cmd = Nothing
    'close Oracle connection
    If Not ORConn Is Nothing Then
    If not ORConn.State = 0 Then
    ORConn.Close()
    End If
    ORConn.Dispose()
    End If
    ORConn = Nothing
    If UCase(sPosition) = "MANAGER" Then
    Me.Hide()
    Dim CallMenu As New Menu()
    CallMenu.ShowDialog()
    End If
    LoginBtn.Enabled = False
    End Sub
    If you need further assistance with the code, please let me know.
    Regards,
    M. R.

Maybe you are looking for