View Link between two query views

Hi is it possible to create a view link between two views having the where clause bind variables.
How you set the bind variables at the run time for the View objects. It is giving hard time for me to use the Master view in the XmlData bean to generate the Xml document.
I am able to set the Master views bind variables, but for view link destination view
where clause bind variables are not able to set ( link object link condition bind variables are binded run time but the views where chause bind variables of destination view are unable to setand bind)
Thanks
null

Easiest way to do this is to add additional transient attributes to your master view object, and then include those additional transient attributes in the list of source attributes for your view link. This way, you can get BC4J to automatically refer to their values with no additional code on your part.

Similar Messages

  • View link between 2 public view object(PVO)

    Hi,
    Can we create a view link between 2 Public View Object(PVOs)? Is as same as creating view link b/w normal VOs.
    Regards,
    Suresh

    Hi,
    whats mean Public View Object? do you use BI?

  • Create view link between two view objects (from programmatic data source)

    Hi Experts,
    Can we create a link between two view objects (they are created from programmatic datasource ; not from either entity or sql query). If yes how to create the link; ( i mean the like attributes?)
    I would also like to drag and drop that in my page so that i can see as top master form and the below child table. Assume in my program i will be only have one master object and many child objects.
    Any hits or idea pls.
    -t

    Easiest way to do this is to add additional transient attributes to your master view object, and then include those additional transient attributes in the list of source attributes for your view link. This way, you can get BC4J to automatically refer to their values with no additional code on your part.

  • View Link on two programmatic view objects

    Hello,
    I use Build JDEVADF_11.1.1.1.0_GENERIC_090615.0017.5407
    I have two programmatic View Objects with data from other sources (an ArrayList in my example).
    Now I would like to create a View Link on it. How can I do this?
    I'm quite new on Java and ADF...
    I know it is possible because I already found Steve's example 132 here [http://blogs.oracle.com/smuenchadf/examples/|http://blogs.oracle.com/smuenchadf/examples/]
    But could somebody create a simple example based on my example classes below (which is understandable for a newbie like me ;-) ?
    Has been asked already here, but I did not found a solution as yet.
    Error with view link and ADF table Tree
    This is my example code for the view objects:
    Employee.java:
    private Number empno;
    private String ename;
    private Number dept;
    with getters and setters...
    Department.java
    private Number deptno;
    private String dname;
    with getters and setters...
    public class StaticDataDepartmentsImpl extends ViewObjectImpl {
    int rows = -1;
    private List<Department> departments = new ArrayList<Department>();
    protected void executeQueryForCollection(Object rowset, Object[] params,
    int noUserParams) {
    // Initialize our fetch position for the query collection
    setFetchPos(rowset, 0);
    super.executeQueryForCollection(rowset, params, noUserParams);
    // Help the hasNext() method know if there are more rows to fetch or not
    protected boolean hasNextForCollection(Object rowset) {
    return getFetchPos(rowset) < rows;
    // Create and populate the "next" row in the rowset when needed
    protected ViewRowImpl createRowFromResultSet(Object rowset,ResultSet rs) {
    ViewRowImpl r = createNewRowForCollection(rowset);
    int pos = getFetchPos(rowset);
    populateAttributeForRow(r, 0, departments.get(pos).getDeptno());
    populateAttributeForRow(r, 1, departments.get(pos).getDname());
    setFetchPos(rowset, pos + 1);
    return r;
    // When created, initialize static data and remove trace of any SQL query
    protected void create() {
    super.create();
    // Setup string arrays of codes and values from VO custom properties
    initializeStaticData();
    rows = (departments != null) ? departments.size() : 0;
    // Wipe out all traces of a query for this VO
    getViewDef().setQuery(null);
    getViewDef().setSelectClause(null);
    setQuery(null);
    // Return the estimatedRowCount of the collection
    public long getQueryHitCount(ViewRowSetImpl viewRowSet) {
    return rows;
    // Subclasses override this to initialize their static data
    protected void initializeStaticData() {
    Department d1 = new Department();
    d1.setDeptno(new Number(10));
    d1.setDname("IT");
    Department d2 = new Department();
    d2.setDeptno(new Number(20));
    d2.setDname("HR");
    departments.add(d1);
    departments.add(d2);
    // Store the current fetch position in the user data context
    private void setFetchPos(Object rowset, int pos) {
    if (pos == rows) {
    setFetchCompleteForCollection(rowset, true);
    setUserDataForCollection(rowset, new Integer(pos));
    // Get the current fetch position from the user data context
    private int getFetchPos(Object rowset) {
    return ((Integer)getUserDataForCollection(rowset)).intValue();
    public class StaticDataEmployeesImpl extends ViewObjectImpl {
    int rows = -1;
    private List<Employee> employees = new ArrayList<Employee>();
    protected void executeQueryForCollection(Object rowset, Object[] params,
    int noUserParams) {
    // Initialize our fetch position for the query collection
    setFetchPos(rowset, 0);
    System.out.println("in executeQueryForCollection");
    super.executeQueryForCollection(rowset, params, noUserParams);
    // Help the hasNext() method know if there are more rows to fetch or not
    protected boolean hasNextForCollection(Object rowset) {
    System.out.println("in hasNextForCollection. Rows:" + rows);
    return getFetchPos(rowset) < rows;
    // Create and populate the "next" row in the rowset when needed
    protected ViewRowImpl createRowFromResultSet(Object rowset,ResultSet rs) {
    ViewRowImpl r = createNewRowForCollection(rowset);
    int pos = getFetchPos(rowset);
    System.out.println("in createRowFromResultSet. Pos=" + pos);
    populateAttributeForRow(r, 0, employees.get(pos).getEmpno());
    populateAttributeForRow(r, 1, employees.get(pos).getEname());
    populateAttributeForRow(r, 2, employees.get(pos).getDept());
    setFetchPos(rowset, pos + 1);
    return r;
    // When created, initialize static data and remove trace of any SQL query
    protected void create() {
    super.create();
    // Setup string arrays of codes and values from VO custom properties
    initializeStaticData();
    rows = (employees != null) ? employees.size() : 0;
    System.out.println("in create(). Rows=" + rows);
    // Wipe out all traces of a query for this VO
    getViewDef().setQuery(null);
    getViewDef().setSelectClause(null);
    setQuery(null);
    // Return the estimatedRowCount of the collection
    public long getQueryHitCount(ViewRowSetImpl viewRowSet) {
    return rows;
    // Subclasses override this to initialize their static data
    protected void initializeStaticData() {
    Employee e1 = new Employee();
    e1.setEmpno(new Number(2333));
    e1.setEname("Emp1");
    e1.setDept(new Number(10));
    Employee e2 = new Employee();
    e2.setEmpno(new Number(1199));
    e2.setEname("Emp2");
    e2.setDept(new Number(20));
    Employee e3 = new Employee();
    e3.setEmpno(new Number(3433));
    e3.setEname("Emp3");
    e3.setDept(new Number(10));
    Employee e4 = new Employee();
    e4.setEmpno(new Number(5599));
    e4.setEname("Emp4");
    e4.setDept(new Number(20));
    Employee e5 = new Employee();
    e5.setEmpno(new Number(5676));
    e5.setEname("Emp5");
    e5.setDept(new Number(10));
    Employee e6 = new Employee();
    e6.setEmpno(new Number(7867));
    e6.setEname("Emp6");
    e6.setDept(new Number(20));
    employees.add(e1);
    employees.add(e2);
    employees.add(e3);
    employees.add(e4);
    employees.add(e5);
    employees.add(e6);
    // Store the current fetch position in the user data context
    private void setFetchPos(Object rowset, int pos) {
    if (pos == rows) {
    setFetchCompleteForCollection(rowset, true);
    setUserDataForCollection(rowset, new Integer(pos));
    // Get the current fetch position from the user data context
    private int getFetchPos(Object rowset) {
    return ((Integer)getUserDataForCollection(rowset)).intValue();
    Who can help?
    Thnx in advance!
    Rolf

    Rolf,
    I guess when we try to do it for you, we end up with almost the sample code provided by Steve Muench.
    So there from my point of view it doesn't make sense to do it all over.
    Take some time and study the sample code, run it without changes and after that try some changes which suits your use case better.
    If you don't understand what's going on in the sample post the question here and we try to help you.
    Timo

  • RE: Swapping two query views based on filter value

    Hi Can anyone tell me how do I swap between two query views for a web item based on one filter selection.
    Thanks in advance
    Message was edited by:
            Chandra Hasa Reddy Samala

    Hi,
    If you want to copy list item with Person column to another list, here are two solutions for your reference:
    1.Use SharePoint Designer workflow to create item in another list when there is item added in the current list, there is a workflow action “Create List Item”
    will meet your requirement. The string in Person column will still be a hyperlink in the other list and you can apply filter on it.
    Workflow actions quick reference
    http://msdn.microsoft.com/en-us/library/office/jj164026(v=office.15).aspx
    2.Use JavaScript Client Object Model to copy item to other list, you can put the script into a Content Editor Web Part.
    JavaScript Client Object Model
    http://msdn.microsoft.com/en-us/library/office/hh185006(v=office.14).aspx
    More information about
    using JavaScript Client Object Model to retrieve and create/update list item:
    http://msdn.microsoft.com/en-us/library/office/hh185007(v=office.14).aspx
    http://msdn.microsoft.com/en-us/library/office/hh185011(v=office.14).aspx
    Best regards
    Patrick Liang
    TechNet Community Support

  • View link between VO from two application modules

    Is it possible to create view link between VOs from 2 different Application modules?

    Here is what it says:
    SymptomsYou have an ADF BC (BC4J) project and you are getting the following error:
    oracle.jbo.domain.Number; local class incompatibleA more detailed error looks similar to:
    oracle.jbo.domain.Number; local class incompatible: stream classdesc
    serialVersionUID = -7171468674200794918, local class serialVersionUID =
    -6507359405709672486
    CauseThis problem is caused by either that:
    You have inadvertently mixed two mutually exclusive domain libraries like "BC4J Generic Domains" (bc4jdomgnrc.jar) and "BC4J Oracle Domains" (bc4jdomorcl.jar).
    or
    You have added the "BC4J Datum" library (bc4jdatum.jar) to your middle-tier class path, and are trying to use a JDBC driver different from the one that ships with JDeveloper 10g in the box.
    The BC4J Generic Domains and the BC4J Oracle Domains are never meant to be used in the same application classpath. They contain different implementations of the same set of classes, one destined for use in Oracle JDBC driver environments, and the other for use with other non-Oracle JDBC drivers.
    The BC4J Datum library is designed for use in a thin-client Classpath that is remotely accessing an ADF Business Components middle tier deployed as an EJB Session bean. It contains only the domain classes (typically jar'ed up as part of the whole Oracle JDBC Driver JAR) without having to have the rest of the JDBC Driver JAR on the thin client. SolutionPlease check if any of the above suggested scenarios is applicable to your application.
    If you have the BC4J Generic Domains and the BC4J Oracle Domains in the same project despite that they are never meant to be used in the same application classpath you will get this error. They contain different implementations of the same set of classes, one destined for use in Oracle JDBC driver environments, and the other for use with other non-Oracle JDBC drivers.
    Goto the Project Properties for you project.
    Select Profiles -> <Profile Name> -> Libraries
    Check in the Selected list (to the right) if you have both BC4J Generic Domains and the BC4J Oracle Domains there. If so, remove the one not appropriate for your project.

  • How to switch between two query in Web templete.

    Hi all,
      Here i am facing problem to switch between two query in web template by using one 'table' web item. is there any way to use hyperlink 'SAP_BW_URL' and we can switch to query. here i am using these HTML code..
    <table><tr><td class="SAPBEXBtnStdBorder" cellspacing="0" cellpadding="0" border="0"><tr><td>
    <table><tr><td class="sapbexbtnstd" ><A href="<SAP_BW_URL cmd='reset_item' item='table_data' query_ID='ZSD_ZSD_M01_Q20' apply_cmd_on_target= "X">" >Switch to other query</A></td></tr></table>
    but i am not getting correct functionality.
    please help me to solve this problem.
    I know the best way to say thanks in SDN.
    thanks
    Kiran Patel

    Kiran,
      Use the web api reset_data_provider as links or in select option in HTML.
       Onchange event of this select option should call JAVASCRIPT method and
       this in turn resets the current dataprovider to your concerned one.
       How to change graphs:
       The graph item has the default data provider:
       <object>
             <param name="OWNER" value="SAP_BW"/>
             <param name="CMD" value="GET_ITEM"/>
             <param name="NAME" value="CHART_1"/>
             <param name="ITEM_CLASS" value="CL_RSR_WWW_ITEM_CHART"/>
             <param name="DATA_PROVIDER" value="DATAPROVIDER_1"/>
             <param name="TMP_CHART_DATA_HANDLE" value="IIP_49MOXB0UVNOMM6JOZMZU7QO21"/>
             ITEM:            CHART_1
       </object>
      So if you change the DATAPROVIDER_1 using RESET_DATA_PROVIDER to your concerned DP, this changes chart as well !!
       Please use this method and refer to sample code for Onchange Event on SELECT OPTION:
      <HTML>
    <HEAD>
    <script>
    function callDP() {
         if(document.forms[0].dp.value == "1") {
            //form your URL here..
           url = SAP_BW_URL_Get() + "&CMD=RESET_DATA_PROVIDER&DATA_PROVIDER_1=..&...";
            SAPBWOpenURL(url);
            //or docuemtn.location.href = url..
            //etc..
    </script>
    </HEAD>
    <BODY>
    <form>
    <select name="dp" onChange="javascript:callDP();">
    <option value="1">1</option>
    <option value="2">2</option>
    </select>
    </form>
    </BODY>
    </HTML>
    HOPE THIS HELPS !!!

  • Link Between two worksheets in Discoverer

    Hi...
    I'm trying to create a link between two worksheets without success.
    What I have is a 'General Ledger' worksheet which lists the journal source for a particular account code that is selected by the user via a parameter. Say the journal source is Accounts Payable invoices, what I want to do is have another worksheet which is 'Accounts Payable' and on that worksheet I want to be able to list all the invoices that make up the journal total on the 'General Ledger' worksheet.
    I have tried to create a link using a sub query condition but when I run the report, the first part 'General Ledger' works fine but when I click on the 'Accounts Payable', I get a "Invalid Number" error message.
    I am going to need to create these type of links for various reports.
    I would be very grateful if anyone can please advise on how to create the link.
    Thanks

    I think you're on the right track with the subquery. So, the wrong number error must be related to the format of the columsn you use for the subquery.
    Alternatively, if the account number you've created the parameter for in sheet 1, you can use the same parameter again for sheet 2 (then check "only one value for all sheets" for that parameter). But this obviously only works if that account number is in the second sheet too...

  • Change or delete the docflow link between two existing documents

    Hi All,
    Is there any FM or soulution to change the doc flow link between two documents .
    For ex .. i have document A and document B , and created a doc flow link from A to B , Now i have to change the succeeding document  to C
    I have tried to modify the doc link ,but its not working using crm_order_maintain.I thought of deleting the link between A and B and then create a new link Between A and C , but deletion of link bewteen A and B is also not working.
    I have checked with FMs CRM_DOC_FLOW_DELETE_CHECK_EC and CRM_DOC_FLOW_DELETE_EC, followed by CRM_ORDER_SAVE AND COMMIT . i could not find any exception from this FMs , but still the doc link is not deleted.
    Pls share if you have any suggestions.
    Regards,
    Nithish

    Hello
    I wrote a report to delink items from document flow. I uploaded it [here|http://wiki.sdn.sap.com/wiki/display/CRM/Removelinksfromdocumentflow].
    Please, use with caution and always perform careful tests before you run it in a production envinronment.
    Hope it helps
    Joaquin
    Edited by: Joaquin Fornas on Nov 15, 2011 11:49 AM

  • How to get the view link definition from the view link accessor

    Hi,
    I am using Jdev 10.1.3 and ADF BC. I am trying to do deep copy in a master/details view, after the new child record is created, I want to update the foreign key attribute. I know I can get the list of attribute definitions from the row in the view object, which include the view link accessors, I am wondering if I can get the view link definition from the view link accessors, so that I can get the source and destination attribute names.
    Thanks!

    Hi,
    you should get this through
    ViewObject vo = this.findViewObject("LocationsView1");
    int indx = vo.getAttributeIndexOf("DepartmentsView");
    ViewAttributeDefImpl vAttrDefImpl = (ViewAttributeDefImpl) vo.getAttributeDef(indx);
    ViewLinkDefImpl vdefImpl = (ViewLinkDefImpl) vAttrDefImpl.findViewLinkDefImpl();
    Note that this code starts from the ApplicationModuleImpl class, which is why I used this.findViewObject().
    Frank

  • Linking between two workspaces

    Good afternoon all,
    I was wondering if there was anyway for me to link between two workspaces on the same schema.
    What I currently have set up is two workspaces (1 and 2). I have done a lot of work on 1 and built a Single Sign On application to manage my applications. Workspace 2 was created for a separate team, but I would like some sort of authentication. I was wondering if there was anyway for me to leverage my existing app in Workspace 1 to authenticate for applications in Workspace 2.
    My guess is that it's not possible, but I figured I might as well ask around to see if there is some weird hack around it.
    Thanks in advance,
    Ivan

    Alright I'll post it on there. Figured that InDesign users would know more about the links and how to set them up. Thanks for the advice.

  • Use of  "findByMultipleParameters" for   "OR " between two Query Filters

    Hi,
    I am also working in CE7.1 .I have  a query regarding the use of  "findByMultipleParameters" .
    That is how to use "OR " between two Query Filter condition,because if we add multiple queries into Query Filter List it will by default taking "AND " .
    For an example, I have to pull data from a table/BO with a condition col A = 10 OR ( col B > 100 AND col c = "XYZ") .
    My code snippet looks like given below.......
    List queryFilters = new ArrayList();
    QueryFilter queryFilterOne = QueryFilterFactory.createFilter("ROLLUMBER",Condition.EQ, rollNumber);
    QueryFilter queryFilterTwo = QueryFilterFactory.createFilter("NAME",Condition.EQ, "123");
    queryFilters.add(queryFilterOne);
    queryFilters.add(queryFilterTwo);
    List students = studentServiceLocal.findByMultipleParameters(queryFilters, false, "xyz");
    I have tried all these and found all of them deprecated,Please suggest something appropriate.Your quick response will help a lot.
    //queryFilterOne.setAction(QueryFilter.OPERATION_OR);
    //QueryFilterFactory.createBoolOperator(queryFilterOne.OPERATION_OR);
    //queryFilters.add(QueryFilter.OR);
    //queryFilters.add(queryFilterOne.setOperation(QueryFilter.OPERATION_OR));
    My another Query is what is the role of implCheck(Boolean),findByName(String) in "findByMultipleParameters()" ?
    Thanking you for your help in advance.
    Regards,
    Sonali
    Edited by: Sonali Das on Sep 14, 2010 2:32 PM

    Hi Praveen/Harris,
    As Mr Bhanu said , we can get the result by using formula variable defined on attribute with replacement path as processing type.
    There is document in https://websmp101.sap-ag.de/bi
    in infoindex->How to Calculate with attributes
    To findout the difference between formula variable and current date, define one more formula variable with processing as custoemr exit.And fill this variable with sy-datum or something else.
    with rgds,
    Anil Kumar Sharma .P

  • Link between two or more reports

    Hi All,
    I want to make a link between two Hyperion Financial Reports. I'm working on HFR 9.3.1 version.
    For example :-
    There must be an option in report, like a hyperlink to open another report. After a click on the link it will open the linked report.
    I tried one option "Add releated contents" but that works only on grid which are having cell values but what I'm looking is to give a link on text and from that text link user will able to navigate.
    Regards,

    Sorry I just thought of a workaround
    You do have to use related content on a data value but you can use formatting to hide everything but the link. Use the REPLACE tab within the cell format to relace the data value with a text string (what you want your URL to display as). If you want it as a menu then you could do this in a seperate grid altogether to save you having to mess with your actual report grid too much.
    Hope this helps
    Stuart

  • View link between calculated attributes

    Hi all,
    I'm having a problem with a view link. See, I'm linking two view objects on attributes that are calculated. The two view objects are result of sql query (not EO based) - plus, this attribute is present in the SQL query and in the db table for both view object.
    The SQL query is like, for both view object :
    select to_char(DATE_FO, 'dd/MM/yyyy), a, b, from ...
    And, as I said, I made a view link on these attributes. The cardinality is 1 to *.
    When testing the ApplicationModule, I'm getting
    (oracle.jbo.SQLStmtException) JBO-27122: SQL error during statement preparation. SELECT ....... ) QRSLT WHERE DATETOCHAR = :Bind_ToCharGdaCrahDateCrahDdMm
    ----- Level 1: Detail 0 -----
    (java.sql.SQLException) ORA-00904: "DATETOCHAR" : identificateur non valide
    DATETOCHAR is the alias of the calcultated attribute in detail vo.
    Please help ! Also I've been reading Steve's article : urlhttp://radio.weblogs.com/0118231/2003/11/13.html[url] ; what is jbo.viewlink.consistent property exactly ?
    Regards
    Luc

    Hi again,
    ok I found it ... I needed to add an alias in the SQL query and override the default sql where clause in the view link. Something weird btw, because the alias in the sql query seems to be not bind to the alias property in the attribute properties... and it add another attribute. But it works fine.
    Therefore, if Steve muench might explain jbo.viewlink.consistent property, I'm stil interested in knowing that :)
    Luc

  • View link between view based on entity(table) and view based on stored proc

    I've created a view based on a stored procedure. I need to link this view to a view based on an entity which is based on a table.
    I can create the view without issue, but when I attempt to run the application module that contains the relationship I get this error:
    (oracle.jbo.InvalidOperException) JBO-26016: Cannot set user query to view "SalesentityModuleApiView2" because it is a destination in a view link
    One thing that may be notable about this is that this view started out based on a database view. I later overrode the select related methods using the example here:
    http://download-east.oracle.com/docs/html/B25947_01/bcadvvo008.htm
    Any ideas? I will gladly post some code if someone will let me know what might help diagnose this.

    Hi,
    I solved my problem with adding transient field, and changing the value of it (true | false) on set method of field that can be changed so I can get which row was updated. What exactly do you mean when you say not updateable, I'm using a vo with no entity, and I can add, remove rows, in fact I think it's a good solution because I don't want to write to database immediately.

Maybe you are looking for

  • Wireless LAN does not work after restart

    Hey My brand new laptop suddenly went blank earlier today and when I restarted it I noticed my wireless internet won't work. It is also asking me to install some new driver, the Network Controller? I am confused as everything was working fine and sud

  • FCP 6 won't open

    I just reinstalled FCP Studio 2 and FCP 6, compressor, Motion or Soundtrack Pro will open. DVD Studio Pro, Live Type and Cinema Tools will. Yes I trashed the preferences and added the updates?

  • Apache Web Server not working correctly

    Hello all, I have enabled web sharing and put a file in my "sites" folder under my username. I have instructed my friend to paste the link into his browser, he is using Leopard 10.5.5 as well, and it says that Safari can not find the server. The box

  • Problem with material setup in MM

    Hi Expert Am a student right now learning SAP course, need advice to my problem I have an error message which said " MRP type VM required forecast data to be maintain" ? I am clueless what is the error about ? In addition i have also entered under MR

  • HT201317 if I accidentally delete a video from iPhoto, can I recover in photo stream or somewhere else?

    If I accidentially delete a vuideo from my iphone, can I recover it in photo stream or elsewhere on my iphone or icloud account?