Listing tables/views/objects

Hi all,
The database I am working employs schemas to restrict accesses. When I use metadata to describe some objects (thought to be views), they turns out to be synonyms instead of being a table/view! As a result, using:
conn->getMetaData("object", MetaData::PTYPE_TABLE) fails.
However, using apps like toad/navigator, they are able to list the views/tables accessible in the schema. How do I use the metadata class to list objects like schemas and views?

I doubt navigator uses OCCI either. The most straightforward way is simply query the metadata directly from the catalog. ALL_VIEWS (for example) probably has the mtadata you want for any view (or USER_VIEWS for a connected user).
SQL> desc all_views
Name Null? Type
OWNER NOT NULL VARCHAR2(30)
VIEW_NAME NOT NULL VARCHAR2(30)
TEXT_LENGTH NUMBER
TEXT LONG
TYPE_TEXT_LENGTH NUMBER
TYPE_TEXT VARCHAR2(4000)
OID_TEXT_LENGTH NUMBER
OID_TEXT VARCHAR2(4000)
VIEW_TYPE_OWNER VARCHAR2(30)
VIEW_TYPE VARCHAR2(30)
SUPERVIEW_NAME VARCHAR2(30)
SQL>

Similar Messages

  • Problem occured when create a tree table for master-detail view objects using SQL queries?

    I am programming a tree table for master-detail view objects using SQL queries and these 2 view objects are not simple singel tables queries, and 2 complex SQL are prepared for master and view objects. see below:
    1. Master View object (key attribute is SourceBlock and some varaible bindings are used for this view object.)
    SELECT  cntr_list.SOURCE_BLOCK,                   
            sum(                   
             case when cntr_list.cntr_size_q = '20'                   
                  then cntr_list.cntr_qty                   
                  else 0 end ) as cntr20 ,                   
            sum(                   
             case when cntr_list.cntr_size_q = '40'                   
                  then cntr_list.cntr_qty                   
                  else 0 end ) as cntr40 ,                   
             sum(                   
             case when cntr_list.cntr_size_q = '45'                   
                  then cntr_list.cntr_qty                   
                  else 0 end ) as cntr45                    
    FROM (       
        SELECT yb1.BLOCK_M as SOURCE_BLOCK,       
               scn.CNTR_SIZE_Q,        
               count(scn.CNTR_SIZE_Q) AS cntr_qty        
        FROM  SHIFT_CMR scm, SHIFT_CNTR scn, YARD_BLOCK yb1, YARD_BLOCK yb2       
        WHERE       
        scm.cmr_n = scn.cmr_n             
        AND (scm.plan_start_dt BETWEEN to_date(:DateFrom,'YYYY/MM/DD HH24:MI:SS') AND to_date(:DateTo,'YYYY/MM/DD HH24:MI:SS')                 
        OR scm.plan_end_dt BETWEEN to_date(:DateFrom,'YYYY/MM/DD HH24:MI:SS') AND to_date(:DateTo,'YYYY/MM/DD HH24:MI:SS'))                 
        AND scm.shift_mode_c = :ShiftModeCode                           
        AND scm.end_terminal_c = :TerminalCode      
        AND scm.start_terminal_c = yb1.terminal_c                  
        AND scm.start_block_n = yb1.block_n                  
        AND substr(scn.start_location_c,(instr(scn.start_location_c,',',1,5)+1),instr(scn.start_location_c,',',1,6)-(instr(scn.start_location_c,',',1,5)+1)) BETWEEN yb1.slot_from_n AND yb1.slot_to_n                  
        AND scm.end_terminal_c = yb2.terminal_c                  
        AND scm.end_block_n = yb2.block_n                  
        AND substr(scn.end_location_c,(instr(scn.end_location_c,',',1,5)+1),instr(scn.end_location_c,',',1,6)-(instr(scn.end_location_c,',',1,5)+1)) BETWEEN yb2.slot_from_n AND yb2.slot_to_n           
        AND scn.status_c not in (1, 11)             
        AND scn.shift_type_c = 'V'             
        AND scn.source_c = 'S'       
        GROUP BY yb1.BLOCK_M, scn.CNTR_SIZE_Q       
    ) cntr_list       
    GROUP BY cntr_list.SOURCE_BLOCK
    2. Detail View object (key attributes are SourceBlock and EndBlock and same varaible bindings are used for this view object.)
    SELECT  cntr_list.SOURCE_BLOCK, cntr_list.END_BLOCK,                
            sum(                     
             case when cntr_list.cntr_size_q = '20'                     
                  then cntr_list.cntr_qty                     
                  else 0 end ) as cntr20 ,                     
            sum(                     
             case when cntr_list.cntr_size_q = '40'                     
                  then cntr_list.cntr_qty                     
                  else 0 end ) as cntr40 ,                     
             sum(                     
             case when cntr_list.cntr_size_q = '45'                     
                  then cntr_list.cntr_qty                     
                  else 0 end ) as cntr45                      
    FROM (         
        SELECT yb1.BLOCK_M as SOURCE_BLOCK,     
               yb2.BLOCK_M as END_BLOCK,  
               scn.CNTR_SIZE_Q,          
               count(scn.CNTR_SIZE_Q) AS cntr_qty          
        FROM  SHIFT_CMR scm, SHIFT_CNTR scn, YARD_BLOCK yb1, YARD_BLOCK yb2         
        WHERE         
        scm.cmr_n = scn.cmr_n               
        AND (scm.plan_start_dt BETWEEN to_date(:DateFrom,'YYYY/MM/DD HH24:MI:SS') AND to_date(:DateTo,'YYYY/MM/DD HH24:MI:SS')                   
        OR scm.plan_end_dt BETWEEN to_date(:DateFrom,'YYYY/MM/DD HH24:MI:SS') AND to_date(:DateTo,'YYYY/MM/DD HH24:MI:SS'))                   
        AND scm.shift_mode_c = :ShiftModeCode                             
        AND scm.end_terminal_c = :TerminalCode        
        AND scm.start_terminal_c = yb1.terminal_c                    
        AND scm.start_block_n = yb1.block_n                    
        AND substr(scn.start_location_c,(instr(scn.start_location_c,',',1,5)+1),instr(scn.start_location_c,',',1,6)-(instr(scn.start_location_c,',',1,5)+1)) BETWEEN yb1.slot_from_n AND yb1.slot_to_n                    
        AND scm.end_terminal_c = yb2.terminal_c                    
        AND scm.end_block_n = yb2.block_n                    
        AND substr(scn.end_location_c,(instr(scn.end_location_c,',',1,5)+1),instr(scn.end_location_c,',',1,6)-(instr(scn.end_location_c,',',1,5)+1)) BETWEEN yb2.slot_from_n AND yb2.slot_to_n             
        AND scn.status_c not in (1, 11)               
        AND scn.shift_type_c = 'V'               
        AND scn.source_c = 'S'         
        GROUP BY yb1.BLOCK_M, yb2.BLOCK_M, scn.CNTR_SIZE_Q         
    ) cntr_list         
    GROUP BY cntr_list.SOURCE_BLOCK, cntr_list.END_BLOCK
    3. I create a view link to create master-detail relationship for these 2 view objects.
    masterview.SourceBlock (1)->detailview.SourceBlock (*).
    4. I create a tree table using these 2 view objects with master-detail relationship.
    When I set default value for variable bindings of these 2 view objects and the matching records exist, tree table can work well. I can expand the master row to display detail row in UI.
    But I need to pass in dymamic parameter value for variable bindings of these 2 view objects, tree table cannnot work again. when I expand the master row and no detail row are displayed in UI.
    I am sure that I pass in correct parameter value for master/detail view objects and matching records exist.
    Managed Bean:
            DCIteratorBinding dc = (DCIteratorBinding)evaluteEL("#{bindings.MasterView1Iterator}");
            ViewObject vo = dc.getViewObject();
            System.out.println("Before MasterView1Iterator vo.getEstimatedRowCount()="+ vo.getEstimatedRowCount());
            System.out.println("Before MasterView1Iterator ShiftModeCode="+ vo.ensureVariableManager().getVariableValue("ShiftModeCode"));
            vo.ensureVariableManager().setVariableValue("DateFrom", dateFrom);
            vo.ensureVariableManager().setVariableValue("DateTo", dateTo);
            vo.ensureVariableManager().setVariableValue("ShiftModeCode", shiftModeC);
            vo.ensureVariableManager().setVariableValue("TerminalCode", terminalCode);
            vo.executeQuery();
            System.out.println("MasterView1Iterator vo.getEstimatedRowCount()="+ vo.getEstimatedRowCount());
            DCIteratorBinding dc1 = (DCIteratorBinding)evaluteEL("#{bindings.DetailView1Iterator}");
            ViewObject vo1 = dc1.getViewObject();
            System.out.println("Before DetailView1Iterator vo1.getEstimatedRowCount()="+ vo1.getEstimatedRowCount());
            System.out.println("Before DetailView1Iterator ShiftModeCode="+ vo1.ensureVariableManager().getVariableValue("ShiftModeCode"));
            vo1.ensureVariableManager().setVariableValue("DateFrom", dateFrom);
            vo1.ensureVariableManager().setVariableValue("DateTo", dateTo);
            vo1.ensureVariableManager().setVariableValue("ShiftModeCode", shiftModeC);
            vo1.ensureVariableManager().setVariableValue("TerminalCode", terminalCode);
            vo1.executeQuery();
            System.out.println("after DetailView1Iterator vo1.getEstimatedRowCount()="+ vo1.getEstimatedRowCount());
    5.  What's wrong in my implementation?  I don't have no problem to implement such a tree table if using simple master-detail tables view object, but now I have to use such 2 view objects using complex SQL for my requirement and variable bindings are necessary for detail view object although I also think a bit strange by myself.

    Hi Frank,
    Thank you and it can work.
    public void setLowHighSalaryRangeForDetailEmployeesAccessorViewObject(Number lowSalary,
                                                                              Number highSalary) {
            Row r = getCurrentRow();
            if (r != null) {
                RowSet rs = (RowSet)r.getAttribute("EmpView");
                if (rs != null) {
                    ViewObject accessorVO = rs.getViewObject();
                    accessorVO.setNamedWhereClauseParam("LowSalary", lowSalary);
                    accessorVO.setNamedWhereClauseParam("HighSalary", highSalary);
                executeQuery();
    but I have a quesiton in this way. in code snippet, it is first getting current row of current master VO to determine if update variables value of detail VO. in my case, current row is possibly null after executeQuery() of master VO and  I have to change current row manually like below.
    any idea?
                DCIteratorBinding dc = (DCIteratorBinding)ADFUtil.evaluateEL("#{bindings.SSForecastSourceBlockView1Iterator}");
                ViewObject vo = dc.getViewObject();           
                vo.ensureVariableManager().setVariableValue("DateFrom", dateFrom);
                vo.ensureVariableManager().setVariableValue("DateTo", dateTo);
                vo.ensureVariableManager().setVariableValue("ShiftModeCode", shiftModeC);
                vo.ensureVariableManager().setVariableValue("TerminalCode", terminalCode);
                vo.executeQuery();
                vo.setCurrentRowAtRangeIndex(0);
                ((SSForecastSourceBlockViewImpl)vo).synchornizeAccessorVOVariableValues();

  • New View Object not found

    Using the scott schema, in my test workspace I created a BC4J project that had 4 tables/view objects using the wizards and taking all the defaults. I created a UIX-JSP project using those view objects.
    Next I created a new table in the database (LoginMaster). I went back to the BC4J project added the entity object (LoginMaster) and allowed the wizard to build the default view object (LoginMasterView) into package1. Then I opened the properties on the AM (ScottModule)to put the new view object in the Data Model property. I tested the ScotMOdule AM and the view object is there and is accessable.
    I build a jsp page (using the starter form wizard in UIX-JSP category). I then striped out ALL of the default code and cut-n-pasted ALL of the code from another query form that was built by the "Business Components JSP Application" wizard of the UIX-JSP category. I changed the data source name from "EmpView" to "LoginMasterView" and when I run the application I'm told:
    Error Message: Could not locate View Object LoginMasterView in application Package1Module.
    oracle.jbo.JboException: Could not locate View Object LoginMasterView in application Package1Module.
    As I said, the VO LoginMasterView is in package1. I also verified it is coded in package1.xml andd scottmodule.xml, I suspect it was put here by setting the AM properties.
    So what did I leave out or do wrong?
    TIA,
    Ed.

    Edit your package1Module application module and verify that the name of the viewobject in the selected DataModel tree is the same as the name you're providing in your JSP page.
    I belive by default a number suffix is added to the VO names in the APpModule datapanel. Basically only VO usages that are included in the application module data-model are "findable" by default using the findViewObject methods. Yes it is the correct name in the DataModel Tree.
    Your response got me thinking. What files contain the text LoginMasterView? Well, all the files that conatin that text contain exactly that text. I was told package1.xml in the src directory of my BC4J objects project contained the text (which it did). But then I opened the files Package1Module.xml and Package1ModuleImpl.java and noticed they DID NOT conatin that text (even though it seems they should) so I added it to both of these files. But even after I built the BC4J objects project I noticed that the Package1ModuleImpl.class file is not recompiled (still dated July 4, 2002).
    So now I have two new questions:
    1. How come Package1Module.xml and Package1ModuleImpl.java did not get updated? What updates them?
    2. Once Package1ModuleImpl.java is manually updated and the [roject is built why is Package1ModuleImpl.class not recompiled?
    TIA,
    Ed.
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                   

  • Performance Issues due to Loading of ADF/JClient View Objects

    Hi,
    I developed a two-tier ADF/JClient application.
    When the ADF/JClient application opens for the first time, there's a big delay
    However opening it subsequently, takes less than half of the time to open the screen.
    I think it might the xml files of different view objects which the framework loads for the first time, and thus takes a lot of time. And after that, the time to open the application reduces.
    We have around 200 view objects in our application. Can this be the reason?
    If yes, then can we load the view objects before ahead, or can we just load them at the very time they are requested ?
    Thanks,
    Makrand Pare

    Hi Makrand,
    Check this out:
    "Limiting Fetching of Business Components Attributes in ADF Swing
    http://www.oracle.com/webapps/online-help/jdeveloper/10.1.3/state/content/navId.4/navSetId._/vtTopicFile.developing_jclient_applications%7Cjui_plimitingfetching%7Ehtml/
    Note: In local mode deployment (the client and Business Components reside in the same VM), the fetching of attribute properties is not supported.
    You can optimize startup time for a Business Components client application and the remotely deployed Business Components by specifying the list of view object attributes that your client uses. If you create a project without the metadata, by coding to the API, you will want to add fetchAttributeProperties() to the bootstrap code of the client forms with a list of only the attributes used by the form. Without this method call, your client form would fetch all control hint properties (including the attributes format and label for example) for all the attributes of the named view objects in the application module, in a single network roundtrip.
    For example, when you do not intend to use all the attributes of the ADF Swing form's bound view object, with the fetchAttributeProperties() method, your ADF Swing form fetches only the information required to layout your forms, while ignoring the attributes you do not require.
    Note: In local mode deployment (the client and Business Components reside in the same VM), the fetching of attribute pro
    Calling fetchAttributeProperties() will prevent property methods such as getFormat() or getLabel() from being called on the Business Components attribute definition whenever the form is created."
    Vlad

  • Can double tap action override table view tap functionality?

    So I have a table view object in my view...if you select a row, it executes the "didSelectRowAtIndexPath" method in my code.
    I would like the user to have the ability to double-tap (in quick succession) a row however, and register a different type of action. Is this possible to do without overriding the existing "didSelectRowAtIndexPath"...or will I need to write my own single-tap/double-tap logic using onTouchesBegin and then forget about using the whole "didSelectRowAtIndexPath" functionality?
    The main issue, is I don't want to have to lose the benefit of the single-tap and knowing the indexPath value...but when I do a double tap, it won't really matter where I'm at...

    Here's the best info I've found on this topic so far: [http://idevkit.com/forums/general-sdk/43-custom-uitableview-double-tap.html]. It looks like the author has read Handling Single and Multiple Tap Gestures in the +iPhone Application Programming Guide+ and has overcome most of the problems, but I haven't tried any of that code myself yet.

  • How to get the List of Database Objects (Table/View) for a given APEX Page.

    Hi,
    I have an application and that consist of pages like page1,2,3,.....
    *1.* I want a report which can give me the list of all the Pages1,2,3,....
    I am using the following query to acheive this.... THIS IS FINE..
    select a.workspace, a.owner, a.application_name, b.page_id, b.page_name
      from apex_applications a,
           apex_application_pages b
    where a.workspace = b.workspace
       and a.application_id = b.application_id*2. Now, I want for each individual page*, the list all the database objects (tables/views), which that page is using.
    I am using ALL_DEPENDENCIES , but I am not getting the result.
    So, want to know if there any view/table, where I can get the Application Pages & there database object list...
    Thanks,
    Deepak

    Hari,
    Thanks for the response.
    The view APEX_APPLICATION_PAGE_DB_ITEMS will only give me the table name related to any Page Items defined to that page..It will not give me all the database objects..
    suppose we have a Page, having a report based on multiple tables and there is no Page items defined on that page, we will not have any value in this ....DB_ITEMS table. same thing if we have define some PL|SQL(using some table/view) in a Process, that will not be populated in .....DB_ITEMS table. I want some thing like all the database objects (table/views/function/procedure/.....) for a particular Page ID.
    Thanks,
    Deepak

  • Filter view object by selected values from list of values

    Hello,
    I've the following problem with my ADF Application. I have three view objects in my application module. Two of them are connected via a view link. For example take users, who are connected to their departments. The remaining view object consists of factories. Now I want to show the user/department dependency in a tree table and the available factories in a list of values. This list of values should be used to filter the shown users.
    I've already tried to use bind variables in the users view object. But I don't know how to fill them with the value of the list of values.
    Can someboy give me a tip how to solve this problem.
    Best regards,
    Enno

    Hi Enno,
    Try this:
    - Have a AM method with one parameter(which takes user from the list of values) and inside AM method write code to set the bind parameter value and execute the query
    Sample Code
    public void filterByUser(String user){
       //Get your UserViewObject instance to userVO
       userVO.setNamedWhereClauseParam("<Bind_Variable_Name>", user);
       userVO.executeQuery();
    }- Expose the method as client interface
    - Drop the method (Data Control) as a button on to the page and pass the listofvalues value as a value to the method binding param
    Something like this: ${bindings.<User>.inputValue}
    - Finally refresh the master and detail tables based on the ListOfValues selection by setting partialTriggers property to the listofvalues component id
    Hope it is clear
    Sireesha
    Edited by: Sireesha Pinninti on Oct 15, 2009 4:54 AM

  • Cannot select different values from a table in a view object

    Hi everyone,
    I have two tables, Employee : ID, NAME, SALARY, NO_ROLE and role : ROLE_ID, ROLE_EMP. I join them with NO_ROLE and ROLE_ID. I created a view object with these two tables in JDeveloper, I made a LOV with ROLE_EMP and I want to be ale to create an employee with his ID, NAME, SALARY and by choosing a value in the ROLE_EMP list. The problem is that when I choose a ROLE_EMP, I cannot commit because the link between ROLE_EMP and ROLE_ID is not made correctly in ADF.
    In SQL, that's what I'm trying to do: INSERT INTO Employee VALUES (ID, NAME, SALARY, NO_ROLE) WHERE NO_ROLE = ROLE_ID of the ROLE_EMP I have selected.
    Thanks for your help ;)
    PS: I followed this tutorial to do this, but it is not exactly what I want to do: http://docs.oracle.com/cd/E18941_01/tutorials/jdtut_11r2_55/jdtut_11r2_55_2.html

    To be more generic, when I create an employee and select his role_emp (the name of the role) I want that the role_id of the role_emp to commit.

  • Bind a new view object to same adf table at run time

    Hello,
    I have an adf table, that changes based on the type of data the user selects. For example, lets say we have a page that consists of type drop down box at the top and an ADF table at the bottom, which lists data based on the type that is selected from the drop down box. For example, lets say, I have the types (Cars, Planes, and Trains).
    Let's further say we have a view object for cars, one for Planes and one for Trains. Each VO has its own specific set of attributes associated with them, which in should be reflected in the adf table that's on the screen.
    So for example, I select Train..
    My table should contain the columns, num cabs, train type, year built
    For plane, the columns might be Num engines, plane manufacturer, size(ie. 747, 727, etc), year built
    Some type of thing with Cars , cylinders, color, model, year, etc.
    Is there a way to tell my adf table to use a specific view object(ie. Plane, train, or car) at runtime?

    You can try implementing this with dynamic components, e.g. dynamic table
    >
    ADF Dynamic and ADF Read-Only Dynamic Table: Allows you to create a
    table when the attributes returned and displayed are determined dynamically
    at runtime. This component is helpful when the attributes for the
    corresponding object are not known until runtime, or you do not wish to
    hardcode the column names in the JSF page. For more information about
    working with dynamic components, see Section 26.7, "Using a Dynamic Form
    to Determine Data to Display at Runtime."
    >
    Or you use dynamic regions and swithc the region containing the table depending on the selectOneChice. Check http://docs.oracle.com/cd/E24382_01/web.1112/e16182/taskflows_regions.htm and https://blogs.oracle.com/shay/entry/adf_dynamic_regions_switching_just
    Timo

  • How to bind dynamic columns in ADF table to view object

    In the below piece of code i am trying to bind a dynamically added column to my newly added attribute in view object, but the value expression does not set the value of this attibute in the view object please help on what is wrong in this code ??
    <af:table value="#{bindings.ViewObj1.collectionModel}" var="row"
    rows="#{bindings.ViewObj1.rangeSize}"
    emptyText="#{bindings.ViewObj1.viewable ? 'No rows yet.' : 'Access Denied.'}"
    fetchSize="#{bindings.ViewObj1.rangeSize}"
    filterModel="#{bindings.ViewObj1Query.queryDescriptor}"
    queryListener="#{bindings.ViewObj1Query.processQuery}" varStatus="vs"
    selectedRowKeys="#{bindings.ViewObj1.collectionModel.selectedRow}"
    rowSelection="single"
    binding="#{backingBeanScope.backing_createDTpg1.table1}"
    id="table1"
    columnSelection="single"
    partialTriggers="::addCol ::addColAfter ::addColBefore ::removeCol ::addRow ::addRowAfter ::addRowBefore ::removeRow ::addAction ::addActionAfter ::addActionBefore ::deleteAction :::dialog1 :::d1"
    allDetailsEnabled="true" verticalGridVisible="false"
    horizontalGridVisible="true" width="100%" disableColumnReordering="true"
    selectionListener="#{bindings.ViewObj1.collectionModel.makeCurrent}"
    immediate="true" contentDelivery="immediate"
    editingMode="clickToEdit" autoHeightRows="-1">
    <af:column sortProperty="Sno" filterable="false" sortable="false"
    headerText="Sno"
    align="center" width="28" rowHeader="true"
    inlineStyle="font-style:italic;" frozen="true"
    id="sno" selected="true" headerNoWrap="true"
    displayIndex="0">
    <af:outputText id="ot0" value="#{vs.index+1}"/>
    </af:column>
    <af:column id="separatorColumn" align="center"
    width="15" frozen="true" displayIndex="1"
    rowHeader="unstyled" sortable="false"
    filterable="false" selected="false"
    inlineStyle='background-image:url("jheadstart/images/jsp_forward.png"); background-repeat:no-repeat; outline-color:InactiveCaption; outline-style:solid; outline-width:thin;'
    headerText=""/>
    </af:table>
    DCBindingContainer dcBindings =
    (DCBindingContainer)BindingContext.getCurrent().getCurrentBindingsEntry();
    DCIteratorBinding iterBind =
    (DCIteratorBinding)dcBindings.get("ViewObj1Iterator");
    ViewObject decisionTableView1 = iterBind.getViewObject();
    System.out.println("before getAttributeCount :"+decisionTableView1.getAttributeCount());
    int counter = decisionTableView1.getAttributeCount() + 1;
    AttributeDef attribute =
    decisionTableView1.addDynamicAttribute("condition_" + counter);
    RichColumn column = new RichColumn();
    column.setId("condition_" + counter);
    column.setHeaderText("condition_" + counter);
    column.setNoWrap(true);
    RichInputText inputtext = new RichInputText();
    inputtext.setId("condition_"+counter);
    inputtext.setAutoSubmit(true);
    inputtext.setValueExpression("condition_"+counter,
    getValueBinding("#{row.bindings.condition_" +
    counter +
    ".inputValue}"));
    column.getChildren().add(inputtext);
    RichCommandImageLink headerLink = new RichCommandImageLink();
    headerLink.setText("<<Select Fact>>");
    headerLink.setId("conditionLink_" + counter);
    column.setHeader(headerLink);
    List columnList = this.table1.getChildren();
    int separatorColumnIndex =
    findColumnIndex(columnList, "separatorColumn");
    if (columnIndex == -1 || columnIndex > separatorColumnIndex) {
    columnIndex = separatorColumnIndex;
    System.out.println("Column Index :" + columnIndex);
    column.setDisplayIndex(columnIndex);
    this.table1.getChildren().add(columnIndex, column);

    Sorry Frank i could not figure out what u rtrying to say.
    In my case i have ADF table with two predefined coulmns :
    1 : a serial number read only column
    2 : a separator coumn
    I need help to bind the newly created dynamic attribute in the VO with my newly created column in the ADF table which has a input text as child.
    My problem is binding the is not working properly as values entered in the Table are not reflected in the VO.
    And when i insert a new column in between two columns which has already filled values the data in the rows does not shift coreespondingly..
    Edited by: user10281080 on Jul 27, 2009 12:22 AM

  • Using SQL view object to create ADF table

    Hi,
    I have created a column called "Month" (which extracts month from the date column) and another column to count the no. of requests.
    i want to create an ADF table with 2 columns, a column showing the month and another is showing the no. of requests for that month.
    However, now I only managed to achieve the ADF table to show the overall total requests, which means if i add up all the requests for all the months and i get 500
    My ADF table shows this:
    Jan: 500
    Feb: 500
    Mar: 500
    How should I create the view or what should I do to make it such that the no. of request is based on the month?
    Please advice.
    Thanks (:

    Hi,
    For the given situation you can create a Query Based View Object with the following query
    SELECT
    COUNT(TEMP1.DT) REQUEST,
    TO_CHAR(TEMP1.DT, 'Mon') MONTH
    FROM
    TEMP1
    GROUP BY
    TO_CHAR(TEMP1.DT, 'Mon')
    where DT is the date column and temp1 is the name of the database table.
    Following are the steps that i followed to get this query :
    i have taken the following sample table :
    create table temp1
    (srno number primary key,
    dt date)
    *Note you may use any existing column instead of srno or use dt only (i took an extra column as u know we need a primary key /row id)
    the following is the sample data
    insert into temp1 values (1,sysdate);
    insert into temp1 values (2,sysdate);
    insert into temp1 values (3,add_months(sysdate,1));
    insert into temp1 values (4,add_months(sysdate,1));
    insert into temp1 values (5,add_months(sysdate,3));
    insert into temp1 values (6,add_months(sysdate,5));
    the table appears as follows
    SRNO DT
    1 22-JUN-12
    2 22-JUN-12
    3 22-JUL-12
    4 22-JUL-12
    5 22-SEP-12
    6 22-NOV-12
    To start with ADF View Object Creation (Using Jdeveloper 11.1.2):
    Create the view object using Create View Object wizard
    In Step 1. Name window
    set the value for Name : Viewab (you can use any of ur choice)
    In the data source section : select query
    In Step 2. Query window
    a. Click Query builder (it will pop up sql statment window)
    b. In the SQL Statement window
    in quick-pick objects section -> select temp1 table -> shuttle the columns from available list to selected list
    in select clause section -> select srno column from select list-> choose count() function from function drop down list -> insert function -> set alias to REQUEST-> click validate
    now select dt column from select list -> choose to_char() function -> click insert function -> alter the function to to_Char(temp1.DT,'Mon') -> set alias to Month -> click validate
    in the group by clause section -> Click the green symbol to add -> from the expression palette insert dt column -> insert the to_char function -> alter the function to to_char(temp1.DT,'Mon') -> click validate
    in the Entire SQL Query section -> click test query -> in the test query window -> click query result-> you will see the result -> click close -> click ok
    Click next
    Step 3: Bind Variables
    Click Next
    Step 4: Attribute Mappings
    click Finish
    So the view object is ready :)

  • View object that will allow to see data from two tables in a adf table

    Hi,
    I've been have serious issues to resolve this functional requirements with ADF.
    Basically I have two tables let say employee and department.
    A need a read only adf table to show the employees values but I don't want the users to see the department id, instead I want them to see the department name and all this in the same read only adf table.
    I created a view object based on such a query below:
    select employeelastname, employeefirstname, departmentname from employee, department where employee.departmentid = department.departmentid (+)
    Note the outer join here because some employees don't have department assigned but I still want to see them in my read only table.
    The problem is that the view object is based on a sql query and is using calculated attributes instead of entities and I am getting that error "rowkey does not have any primary key attributes" each time I select a row inmy adf read only table. So the popup I defined when the user select a row does not work properly and I need a better solution. I will also have the option for the users to delete a record selected in the read only table so really need entities behind there not just a view.
    My view object also include LOVs but I realized LOVs only work for tables but not for read only tables. Too bad the fonctionality is almost there... So even if I have lovs defined that show the data like I would like it to be seen for tables it does not help for ready only tables. Any way to have read only table working with LOVs (user will not be able to change the values or select another value in the list but at list they would see the department name instead of the department id)?
    Thanks to anyone that would be able to help me on this.
    Stephane

    Let me first say that I would use Shays approach and only under special circumstances (which are beyond this thread) use the solution outlined below:
    You can use the read only VO based on your query without basing it an entities. All you have to do is to mark one or more attributes as primary key in the VO. This should solve the "rowkey does not have any primary key attributes" error.
    Now to delete a row (I'm not sure which row department or employee you mean here) you use the selected read only row, get the PK of the row and call a service method in the application module of in a VO which is based on an entity and remove the row there. You can even use the removeRowWithKey operation from the data control to archive this.
    The second problem I don't understand. If you show the user a read only table there in no need to show a lov as you can't change the value. If your problem is that you need to show the department name instead of the department id, you simply add the department name to the attributes you select with your query.
    Timo

  • Is there any software which displays all form objects - tables, views, etc?

    Dear friends,
    I need to know if we have some software product which opens an Oracle form and shows all objects (tables, views, procedures, functions, and so on) accessed by it.
    For each form, this software should show all operations made in each table - that is, whether form creates, updates, reads or deletes data in each table accessed by the form.
    If there's any software which makes such analysis, please let me know. I'd rather be downloading free software, but a trial version or a paid one can be considered as well.
    Best regards,
    Franklin

    Hello all,
    sorry, I don't know whether my 1st message was clear, so I am trying to rewrite it.
    I'm thinking about a software which creates a database objects list report; this report shows all database objects being accessed by the form - for example, it can list all tables being accessed by the form, showing a CRUD (Create, Read, Update and Delete) for each accessed table, or list all packages being executed by the same form, and so on. For example:
    Form: CLI0001.FMB
    Package -> Operation
    PCK_ACCOUNTS -> E (Execute; but that's a suggestion, we can have 'R' instead)
    Table -> Operation
    ACCOUNTS -> CR (Create + Read)
    PAYMENTS -> D (Delete)
    Sequence -> Operation
    SEQ_ACCOUNTS -> R (Read)
    View -> Operation
    VW_CLIENTES -> R (Read)
    If there's any software which can do it, please let me know. Thanks in advance.
    Best regards,
    Franklin
    Edited by: franklinbrasil on 15/10/2008 19:26

  • Binding a view or query to list\table

    Hi,
    Using NetBeans 6.1
    I managed to easily connect tables to a jTable element, but fail to connect to table (or list) a view or a free sql query. I'm working with MySQL and NB6.1.
    What is the procedure to do the above?

    t_ras wrote:
    The main problem in creating business classes with the data is that I can't load the whole of the DB to classes, there are many related types of them and also a lot of rows.
    So here you have to deice:
    1) load the whole DB at once on load - then you work fast and have all in business classes easy to work with, but then it will be a mess updating back on save since you don't know what has change and you need to get derty with transactions and such creatures.
    2) Work with data "on demand" - forget classes, just put in GUI the data you need. works fast all the time, less problems with transactions issues and enables wasy work with row locking. Then updating you need a very understandable code which probably has bugs, since it is not business logic oriented code, but DB structure oriented.Your thinking is wrong.
    1. Just because there are relations between business objects doesn't mean you have to load all of them into memory when one is selected. You can, for example, do "lazy" fetches, and retrieve related business objects the first time you navigate the relationship.
    2. All interactions with a database should take place within transactions -- there is nothing "dirty" about using transactions.
    3. Working with data "on demand", if I can guess what that ought to mean, doesn't imply throwing OOP design principles out the window.
    I think you need to learn about a persistence framework, like Hibernate . Many of the things you worry about, like " will be a mess updating back on save since you don't know what has change" are cleanly solved by it.

  • List of obsolete objects and tables

    Hi,
    Can anyone give the list of obsolete objects and tables from 4.6c to ECC 6.0 upgrade. Also other upgrade issues and solutions faced for ECC 6.0 upgrade.
    Thanks in advance.

    You may have an overview wirth Solution Browser tool (at the solution point of view) in order to compare functionality between your current system and the ERP 2005.
    at:
    http://solutionbrowser.erp.sap.fmpmedia.com/
    You can get the detailed release information from the following link.
    http://service.sap.com/releasenotes.
    A release note is a brief explanation of new features or changes to the system since the last software release. A release note typically describes a new function or an existing function that has been enhanced or changed.
    I hope this helps.
    Reward Points If helpful
    Regards
    Nilesh

Maybe you are looking for