MyFaces "columns" and "commandLink" problem

I am having an issue with the MyFaces implementation of the the JSF "dataTable" where I am using the MyFaces "columns" tag to generate columns from a List, inside each of these generated columns is a JSF commandLink. The issue I am having is that when a commandLink is pressed I get an actionEvent for every column generated under the "columns" tag not just for the one that was clicked.
Am I just thinking about this wrong?
How can I identify the single commandLink that was clicked?
Here is a code sample:
<t:dataTable rowClasses="MenuItemRow"   value="#Bean.dmMenu}"  var="link" first="0" rows="1">
     <t:columns value="#{Bean.listLinks}" var="link">
         <h:commandLink value="#{link.value}" actionListener="#{Handler.linkPressed}">
          </h:commandLink>
     </t:columns>
</t:dataTable>Thanks for any help.

Hi,
I tried with the steps you have mentioned . i was not able to reproduce your problem
I click still the link : server sendes back page1 instead of page3.It sends back the page 3 itself.
regards
MJ

Similar Messages

  • Problem adding columns and rows in JTable

    hi, hope somebody can help me
    i have some problems when i add columns and later i try to set number of rows in JTable, ocurr some exceptions
    my code is something like thisJTable tabla = new JTable();
    TableColumn tc = new TableColumn();
    tc.setHeaderValue("col1");
    tc.setPreferredWidth(20);
    tabla.getColumnModel().addColumn(tc);up to here everything goes well, my table shows the column, but when i add this line((DefaultTableModel)tabla.getModel()).setNumRows(1);ocurrs the next exception
    Exception occurred during event dispatching:
    java.lang.ArrayIndexOutOfBoundsException: 0 >= 0....
    any ideas????

    oks, that would work when the JTable is created, but now we say that I require a method which adds a new row to the JTable a some moment of execution
    Look some of my code
    i have this in a JFrame...
    JTable tabla = new JTable();
    DefaultTableModel tm = new DefaultTableModel();
    tabla.setModel(tm);
    agrCol("Col1", 80);
    agrCol("Col2", 160);
    agrFil();
    agrFil();
    agrCol(String col, int lon) {
      tm.addColumn(col);
      tabla.getColumn(col).setPreferedWith(lon);
    agrFil() {
      tm.setRowCount(tabla.getRowCount() + 1);
    the jtable shows the 2 columns and 2 rows, but the setPreferedWith work only in the last col, i'm confused

  • Problem in taking the average of a column and grouping by date

    Hi all,
    I created a logical column using a formula in "Administration". The formula is like;
    Duration%=(Duration*100)/(X-Y).
    Then, in "answers", I created a report using Duration% column and another column which is its average. I want to see the average of Duration% values grouped by date.
    The numbers in the report are incorrect. What can be the reason for this? Does using logical column which is derived with a formula cause a problem when we take its average?
    Thanks in advance for your help..

    use avg(Duration% by <"Date Table"."Date Level"> in the answers column.
    substitute "Date Table" with your actual time dimension table name, and "Date Level" with your actual date column that you want to group by.

  • Problem in Combo chart columns and line

    I select chart type is  combo in my vc model  and select data series is columns and line.
    I define 5 series in the chart.
    once i deployed the model the output shows the columns are overwrite in stacked position.
    eg:
    series 1: 10%
    series 2: 20%
    series 3: 45%
    series 4: 25%
    series 5 is line type
    but in the chart the only one column will display,its top value 45% and itself shows 10% and 20% in different color.Don't show the 25% value on that column.
    How to display the chart columns in clustered type in combo chart.
    thanks in advance
    Aravind.S

    Hi
    When you select 'Combo Chart' you will not get options for 'Stacked or Clustered'. By default it will be 'Stacked' chart only. Combo charts are generally used for less number of data series. Normally these charts are best suitable for 2 Data series only.
    Still in your case is there any reason to use 'Combo Chart'? Consider following points -
    1. If you want to use this type of chart then selction of 'Columns + Line' will be difficult because it will treat only 'Last Data Series' as line & all others will be columns & what you said problem will appear.
    2. Instead of that select 'Column + Lines', so that only first 'Data series' will be column & rest all will be 'Lines'. So that you will get better visibility in that graph.
    I think this will help you, If you have nay problem let me know.
    Regards
    Sandeep

  • In XI pro, exporting PDF to Excel problem.  Excel columns and data are not properly aligned.  Help?

    I used 30 day trial of Acrobat XI and all the functions work perfectly.  But, when I buy the program (either download or disk) my PDF that export to Excel is not working.  The excel columns and data are not properly aligned as they should be.  The Trial version aligns everything perfectly.  What is happening?  I use a MAC 10.9.5.  But this shouldn't matter because the trial version works perfectly.  Can anyone help?

    just found out that this is posted in the wrong section.

  • h:commandLink problem

    I think I don't know how to use <h:commandLink> and <h:commandButton> correctly because I have encountered a lot of problems with this two components. Sometimes it works OK, but sometime it doesn't work.
    For example:
    <f:view>
                   <f:loadBundle basename="edu.fudan.glee.view.bundle.MessageBundle" var="bundle" />
                   <jsp:include page="/header.jsp" flush="true" />
                   <h:form id="favoriteForm">
                        <h:dataTable id="favoriteTable" var="video" value="#{UserBean.favorites}">
                             <h:column>
                                  <h:outputText value="#{video.chineseName}"></h:outputText>
                             </h:column>
                             <h:column>
                                  <h:commandLink id="deleteFavorLink" value="#{bundle.deleteButtonLabel}" action="#{UserBean.deleteFavorite}">
                                       <f:param name="videoId" value="#{video.sid}"/>
                                  </h:commandLink>
                             </h:column>
                        </h:dataTable>
                        <h:messages style="font-weight: bold; color: #FF0000;" />
                   </h:form>
                   <%@ include file="footer.jsp"%>
              </f:view>When I click the link, nothing happens except a "#" added to the end of URL(displayed in the borwser). If I replace <h:commandLink> with <h:commandButton>, it works(Of course, <f:param> doesn't work in commandButton).
    My bean is in session scope.
    Why?
    Thanks!
    Message was edited by:
    zhlmmc

    I'm not sure about the "correct" way, but I did the following:
    1. go to http://myfaces.apache.org/download.html and download the jars in MyFaces core, Tomahawk and Tobago
    2. copy all of the core jars into my web app, removing any duplicates of similar names that were there already (including jsf-api and jsf-impl)
    3. copy the tomahawk jar into my web app
    4. I also copied the commons-fileupload jar from Tobago into my web app, but I'm not sure if this is needed.
    This worked for me, by trial-and-error. The information on the apache website and wiki is very obscure and contradictory, some of the links don't point to what they should, and I couldn't find the example .war they mentioned anywhere on the site.
    Good luck

  • Html Iframe and CommandLink Target don't working...

    Hi,
    In my application, I have a PanelGrid with 2 columns. The first column have a form with one InputText and CommandLink to submit a form action. The second column have a Html IFrame only. The code is shown below:
    <h:panelGrid border="1" columns="2" columnClasses="main,menu">
            <h:panelGroup>
                <h:form target="body">
                    <h:outputLabel value="Name:" for="communityName"/>
                    <h:inputText id="communityName" value="#{community_searchBean.name}"/>
                    <h:commandLink type="submit" target="main" action="#{community_searchBean.search}" value="Search"/>
                </h:form>
            </h:panelGroup>
            <h:panelGroup>
                <iframe name="body" style="width:100%;height:100%;"></iframe>
            </h:panelGroup>
    </h:panelGrid>
    ...The CommandLink and Form targets point to Html IFrame, but it doesn�t show the action page. How can i resolve this problem? Any Idea?
    Thanks.

    That looks like a problem with the plugin-container process (OOPP).
    It works if I disable OOPP for the Flash plugin and close and restart Firefox.<br />
    I don't know what goes wrong though.
    See http://kb.mozillazine.org/Plugin-container_and_out-of-process_plugins

  • Lining up Columns and Heading in dataTable

    I am having some trouble lining up my columns with their headings in my dataTable.
    When i use IE the columns and headings line up perfectly.
    When i use Firefox the final column doesn't line up with the last heading.
    If i minmise the application in either browser the headings stay as they are and the columns don't line up with them meaning certain values don't come under their headings when the application is minimised. Has anyone else had this problem?
    any help or suggestions would be really apprecited. Thanks in advance. My dataTable is as follows:
    <t:dataTable id="routeList" value="#{RouteHandler.routeWithIdList}" var="rowElement" cellspacing="0" cellpadding="3"
    border="0" headerClass="listhead" columnClasses="listresults" bgcolor="#FFFFFF" rendered="#{!VirginHandler.selected}">
    <t:column width="104">
                                  <h:commandLink id="editLink" action="#{RouteHandler.prepareAddScheduleAction}" >
                                       <h:outputText value="#{rowElement.carrierCode}"/>
                                       <f:param name="routeDisplayId" value="#{rowElement.routeDisplayId }"/>
                                       </h:commandLink>
                                  </t:column>
    <t:column width="165">
    <h:commandLink id="editLink" action="#{RouteHandler.prepareAddScheduleAction}" >
                                       <h:outputText value="#{rowElement.departureAirport}"/>
                                       <f:param name="routeDisplayId" value="#{rowElement.routeDisplayId }"/>
                                       </h:commandLink>
    </t:column>
    <t:column width="920">
    <h:commandLink id="editLink" action="#{RouteHandler.prepareAddScheduleAction}" >
                                       <h:outputText value="#{rowElement.arrivalAirport}" />
                                       <f:param name="routeDisplayId" value="#{rowElement.routeDisplayId }"/>
                                       </h:commandLink>
    </t:column>
    </t:dataTable>

    When you need a table, use a table. 
    CSS:
    td:nth-child(2) {
         font-weight:bold;
         text-align:right;
    HTML:
    <table cellspacing="0" cellpadding="5">
    <tr>
    <td>Some text here</td>
    <td>Price</td>
    </tr>
    <tr>
    <td>Some text here</td>
    <td>Price</td>
    </tr>
    <tr>
    <td>Some text here</td>
    <td>Price</td>
    </tr>
    </table>
    Nancy O.
    Alt-Web Design & Publishing
    Web | Graphics | Print | Media  Specialists 
    http://alt-web.com/
    http://twitter.com/altweb

  • Apex_application.g_fXX and collection problem

    Hello all!
    In the midst of writing my second apex application, it appears I need to use apex_application functionality to meet my requirements and am seeking assistance.
    I have a table/report with a column link (item_id) and a second column (as a text field) (there are more columns displayed), but I think they are irrelevant to this situation) populated with a value QTY (c002) from a collection where c001 = item_id. What I'm attempting to do is allow someone to enter a qty in the c002 text field, apply the qty change to the collection and reload the page displaying the new quantity value in the report when the column link (image) is selected (page redirects to itself).
    Since it appears that column links are not a SUBMIT, I've put my collection update plsql in a before header process. According to the debug output, this collection insert is executed long before the rendering of the report.
    This is my report plsql;
    declare
    l_query varchar2(4000) := '';
    begin
    l_query := 'select i.INVENTORY_ID, col.c002, ql.QUANTITY_AVAILABLE, i.STRAIN_CODE, i.STRAIN_NAME, i.GENOTYPE, i.AGE, i.SEX, ql.ROOM_NUMBER from SM_INVENTORY i, SM_QUANTITY_LOCATION ql, apex_collections col where ql.STRAIN_ID = i.STRAIN_ID(+) and col.collection_name (+)= ''ORDER'' and col.c001 (+)= i.INVENTORY_ID';
    end;
    This is my update collection plsql (I don't have the insert part yet, but my collection already contains values);
    declare col_item_count number;
    col_seq number;
    item_id number;
    qty number;
    begin
    if apex_collection.collection_exists('ORDER') = FALSE then
    apex_collection.create_collection( p_collection_name => 'ORDER');
    commit;
    end if;
    for i in 1..apex_application.g_f01.count
    loop
    item_id := apex_application.g_f01(i);
    qty := apex_application.g_f02(i);
    select count(c001),seq_id into col_item_count, col_seq
    from apex_collections
    where c001 = item_id
    and collection_name = 'ORDER';
    group by c001, seq_id;
    if col_item_count > 0 then
    apex_collection.update_member(
    p_collection_name => 'ORDER',
    p_seq             => col_seq,
    p_c001 => item_id,
    p_c002 => qty);
    commit;
    end if;
    end loop;
    end;
    Given all this, my collection entry is not updated with the new value of c002 displayed in my report text field.
    Be advised, I've not found documentation about the apex_application package of sufficient detail to allow me to comprehend exactly what gets put into the apex_application.g_fXX values or when, but based on what I've gathered from examples/blogs, I think it contains the report in the currently rendered page, but I honestly don't know.
    Given my assumptions, I'm expecting apex_application.g_f01(1) would be the first row item_id of my report and apex_application.g_f01(2) would be the first row c002 (qty from my collection) of my report. If this is correct, I would expect this would work.
    What might I have missed?
    Thanks!
    Paul
    PS. Honestly, is this methodology the only/easiest way to get my requirement/functionality to work? Is there an easier way?

    OK, tried this - not yet successful. This is what I've got.
    Classic report loaded by;
    declare
    l_query varchar2(4000) := '';
    begin
    l_query := 'select i.INVENTORY_ID, i.INVENTORY_ID inv_id_hold, col.c002, ql.QUANTITY_AVAILABLE, i.STRAIN_CODE, i.STRAIN_NAME, i.GENOTYPE, i.AGE, i.SEX, ql.ROOM_NUMBER from SM_INVENTORY i, SM_QUANTITY_LOCATION ql, apex_collections col where ql.STRAIN_ID = i.STRAIN_ID(+) and col.collection_name (+)= ''ORDER'' and col.c001 (+)= i.INVENTORY_ID';
    end;
    Created a "SAVE" button.
    Set up column inv_id_hold as a hidden tab form element and col.c002 as a text field tab form element (item_id and qty respectively). These should now be available as apex_application.g_f01 and apex_application.g_f02 (right?).
    I have this post submit plsql in a process conditioned to the "SAVE" button.
    declare col_item_count number;
    col_seq number;
    item_id number;
    qty number;
    begin
    if apex_collection.collection_exists('ORDER') = FALSE then
    apex_collection.create_collection( p_collection_name => 'ORDER');
    end if;
    for i in 1..apex_application.g_f01.count
    loop
    item_id := apex_application.g_f01(i);
    qty := apex_application.g_f02(i);
    select count(c001),seq_id into col_item_count, col_seq
    from apex_collections
    where c001 = apex_application.g_f01(i)
    and collection_name = 'ORDER';
    --group by c001, seq_id;*
    if col_item_count > 0 then
    apex_collection.update_member(
    p_collection_name => 'ORDER',
    p_seq             => col_seq,
    p_c001 => item_id,
    p_c002 => qty);
    else
    apex_collection.add_member(
    p_collection_name => 'ORDER',
    p_c001 => item_id,
    p_c002 => qty);
    end if;
    end loop;
    end;
    When I enter something in my qty column and press SAVE, I get "ORA-01403: no data found" being thrown by the plsql process (per debug). Since everything is going on "under the hood" and there is no step debugger in apex, I'm not able to see/understand the process in action and determine where the problem is occurring.
    I got the idea for all of this here - http://apex.oracle.com/pls/otn/f?p=39839:3:5596350954563087::NO which is the shopping cart page of the online store application. But I'm trying to get the quantity edit portion to work on the inventory listing (so a customer can add items to an order simply by providing qty input for a particular line item(s) and saving).
    Any advice?
    Can you write an order processing system in apex that uses a collection to store line items?

  • Filter a column and a row based on two labels

    Hi
    Having a slight problem with an excel table and how to either filter or lookup the value I require.
    Basically the table is a skill matrix that I am trying to create into an app. The columns of the table are Name, and then all the separate areas (Area 1, Area 2, Area 3 etc). The rows are then the persons name in the name column and then a grading of that
    persons skills for each area. So the table looks look this:
    Name.       Area 1.        Area 2.      Area 3.
    John.            1.                1.             3
    Paul.             2.                1.             1
    I have created a gallery with all the names, and another gallery with all the areas - and I would like the values for the areas to show based on these 2 criteria. Tried Lookup which kept throwing up errors and also filter which again threw up errors. Is
    there any way to combine these to get the values showing in a label?
    Thanks

    Thanks. I tried that method and it works but I have too many areas to make it functional within the app experience.
    A bit more information:
    I have a gallery which is linked to Table 1 - this consists of the name of each person and an image - the image is what controls the gallery, touch it and you go to screen 2 which is that person's individual 'page'.
    On this page is the persons image, a label with their name, a drop down box and a text gallery. The drop down box and text gallery are linked to Table 2 - The dropdown is directed by a column in the table which is Zones and the text gallery is filtered by
    these zones into the areas within the zones:
    Zones            Areas            Name1            Name2             
    Name3 ....
    Zone 1           Area 1            3                     
    2                       3
    Zone 1           Area 2            1                     
    3                       2
    Zone 2           Area 3            3                     
    3                       3
    Zone 3           Area 4            1                     
    1                       3
    (This is an example of the table - the areas actually go into close to 100 and split into 6 zones).
    The Text gallery filter works upto a point - it gives me a Header which is based on the correct area - and only shows the Areas for the Zone picked from the drop down box. However, I would like the Body of the text gallery to give me the number for the name
    (which is the same name as picked from gallery 1).
    This is where I am having major problems (spent a week on this upto now and its nearly cost me 2 tablets when I think i have solved it and that little yellow triangle pops up in the body box).
    I have tried Lookup on Table2, using the name from gallery 1 as a the argument but it asks me each time to pick the right column to look in, which would work if I wanted the gallery only to work for a single Name but I would like it to show the rankings
    for the person who is picked from gallery1.

  • Hiding a table column and its contents yet reading the values

    Hi all,
    hope someone can help as i urgently need a solution for this although its probably more of a javascript and html forms question than a JSP - but i couldnt find a good javascript forum - if any one has come across a good JS and HTML - i would appreciate if you would let me have a url for it - in the meantime as i need this urgentely and most JS sites that i have visted and posted on seem to be useless, i havent got a reply back yet , and since i've always found java sun forum good and helpful thought would post it here - hope no one minds it too much . Thanks in advance for any help with resolving my urgent problem.
    overview of question:
    I need to, using an onclick() event read the contents of the 4th cell in the clicked row and set the value of a hidden element � (not sure what element to use here attribute tag? Or some other - but basically, this needs to also be hidden, as I�m going to use this as one of the parameters to send through as part of the form - )
    explanation of question
    So when I do :-
    <td><netui:label value="{container.item.TELECARERID}"/></td> And using javascript :-
    row.cells[4].innerText;I can read the value and print it to screen as :-
    alert('row.cells[4].innerText)) = ' + row.cells[4].innerText);although at this stage I�m not sure how to now set this value to an element in the form so that I can include this value as part of the submit action of the form.
    However when I do the following, which is closer to what I�m trying to achieve (ie hide the 4th column of the table and its values � but when I just hide the value as in:-
    <td><netui:hidden dataInput="{container.item.TELECARERID}" dataSource="" /></td> I can�t use the above (row.cells[4].innerText;), javascript syntax to get to the value although the value is still in the viewsource of the html page.
    How can I hide this forth column of the table yet get the values of the 4th column and also set it to some element of the form so that it can be submitted with the date range as part of a criteria to search against by the backend server.
    the full code (well... relevant parts)
    Here is all the code:
    <table id="table1" class="tablebody" border="1">
            <tbody>
             <tr>
               <th><rpb:columnHeader field="FIRSTNAME"><i18n:getMessage messageName="first_name"/></rpb:columnHeader></th>
               <th><rpb:columnHeader field="LASTNAME"><i18n:getMessage messageName="last_name"/></rpb:columnHeader></th>
              <th><rpb:columnHeader field="LOGONNAME"><i18n:getMessage messageName="logon_name"/></rpb:columnHeader></th>
              <th><rpb:columnHeader field="TEAM"><i18n:getMessage messageName="team"/></rpb:columnHeader></th>
               <th><rpb:columnHeader field="TELECARERID"><i18n:getMessage messageName="telecarer_id"/></rpb:columnHeader></th>
            </tr>
           </netui-data:repeaterHeader>
           <netui-data:repeaterItem>
            <tr bgcolor="#FFFFFF" onMouseOver="this.bgColor='gold';" onMouseOut="this.bgColor='#FFFFFF';" onclick="selectTeleCarer(this)">
            <td><netui:label  value="{container.item.FIRSTNAME}"/></td>
              <td><netui:label value="{container.item.LASTNAME}"/></td>
             <td><netui:label  value="{container.item.LOGONNAME}"/></td>
           <td><netui:label  value="{container.item.TEAM}"/></td> 
            <td><netui:label value="{container.item.TELECARERID}"/></td>
           </tr>
          </tbody>///////and then I�m trying to using the below sepertaely printed javascript set it to the below hidden attribute so that it can be submitted as part of the form
    <netui:hidden tagId="teleCarerId" dataSource="{actionForm.teleCarerId}" dataInput=""/>
                                 <div>
                             <i18n:getMessage messageName="created_between"/>
                                <netui:textBox tagId="data" dataSource="{actionForm.fromDate}"/>
                                <button id="trigger" onclick="jscalendar/calendar.js">...</button>
                               <i18n:getMessage messageName="and"/>
                                <netui:textBox tagId="data1" dataSource="{actionForm.toDate}"/>
                                <button id="trigger2" onclick="jscalendar/calendar.js">...</button>
                            </div>
                    <br />
                    <netui:button value="Submit" type="submit"/>
                </netui:form>/// the java script is :-
    function selectTeleCarer(row)
        if ( row.style ) {
    row.style.backgroundColor = ('gold' == row.style.backgroundColor)?
    'white' : 'gold';
    //document.form.teleCarerId.value = row.cells[4].innerText;
    alert('row.cells[4].innerText)) = ' + row.cells[4].innerText);
    }

    thanks for the reply,
    but i cant use just html like <input type hidden > as i'm using the struts like framework with the netui tags in weblogic where i need to link the tag value to the form bean to be passed to the server . thus i need to use the netui tag , which doesnt have a name but a tagId instead, so i'm using it like this :
    <netui:hidden tagId="teleCarerId" dataSource="{actionForm.teleCarerId}" dataInput=""/>and then in javascrpit doing:
    //document.form.teleCarerId.value = row.cells[4].innerText;but thats not my problem ()as it probably will work and its only an issue after i resolve the first part of my question:-
    which is how do i hide a cloumn in a table and its values so that when the user selects a row i can pass the hidden value of row as part of my form .
    as i mentioned before when i make the cloumn visible as in
      <th><rpb:columnHeader field="TELECARERID"><i18n:getMessage messageName="telecarer_id"/></rpb:columnHeader></th>and give it a visible value:
      <td><netui:label value="{container.item.TELECARERID}"/></td>
           </tr>i can pick up the value fine using the javascript syntax:
    row.cells[4].innerText;however when i hide only the value - which is only part of what i want to do as i want to also hide the column heading so that this part of the table isnt seen- as in:-
    <td><netui:hidden dataInput="{container.item.TELECARERID}" dataSource="" /></td>then i cant use
    row.cells[4].innerText;to pick up the value although it does hide the value and in viewsourec the value is there - is there some other syntax that i should be using here - and also how can i hide the cloumn heading so that the table looks asthtically good on the browser?
    ie. what should i change this line of code to?
      <th><rpb:columnHeader field="TELECARERID"><i18n:getMessage messageName="telecarer_id"/></rpb:columnHeader></th>thanks in advance for any help.

  • Creating a view with existing GeoRaster columns and new SDO_GEOMETRY column

    Hi,
    In a nutshell, I already have 1 real table, which has several attributes including types such as text, numbers etc. but also a GeoRaster column. This table works great, has its metadata stored properly and is spatially indexed; no worries.
    I am then creating a view based on the above mentioned table, including the GeoRaster column. This worked, no problems. However now I want the same view to also have a SDO_GEOMETRY column which explicitly stores the spatial extent for each GeoRaster. Note the original table does not have this SDO_GEOMETRY column. So, I have created a revised SQL statement to create the view, but now it dynamically adds a new column and puts the GeoRaster.spatialextents into the SDO_GEOMETRY column.
    This worked, the data made it into the view, but when we try to view the SDO_GEOMETRY in a viewer, we get errors. I added a system metadata entry for the view, but this did not help. Also, it is not possible to spatially index a view so I knew that was not the problem.
    I think what has happened is the SDO_GEOMETRY column is in a sort of "limbo", where because it was not contained in the original table (and indexed there) and it is not able to be indexed in a view, it cannot be manipulated/viewed/used spatially.
    Here is a snippet describing the original table:
    "IMAGERY_ID" NUMBER NOT NULL ENABLE,
    "CAM_ANGLE_X" NUMBER,
    "CAM_ANGLE_Y" NUMBER,
    "CAM_ANGLE_Z" NUMBER,
    "SPEED" NUMBER,
    "HEADING" NUMBER,
    "IMAGE_GEOR" "SDO_GEORASTER",
    "ACQUISITION_TIME" TIMESTAMP (6),
    "SENSOR_ID" NUMBER,
    "DOWNWARD_LOOKING" CHAR(1 BYTE),
    "ORG_ID" NUMBER,
    "POC_ID" NUMBER,
    "FILE_NAME" VARCHAR2(100 BYTE),
    "CORRELATION_ID" VARCHAR2(256 BYTE),
    And here is the statement I used to create the new view:
    CREATE VIEW level_0_img_view (imagery_id, cam_angle_x, cam_angle_y, cam_angle_z, speed, heading, image_geor, acquisition_time, sensor_id, downward_looking, org_id, poc_id, file_name, correlation_id, geor_extents)
    AS
    SELECT a.imagery_id, a.cam_angle_x, a.cam_angle_y, a.cam_angle_z, a.speed, a.heading, a.image_geor, a.acquisition_time, a.sensor_id, a.downward_looking, a.org_id, a.poc_id, a.file_name, a.correlation_id, a.image_geor.spatialextent
    FROM imagery a
    WHERE a.file_name LIKE '%.lev0';
    Note in the above statement that the "geor_extents" column is the new column added dynamically (and not in the original table). Note the new column with the SDO_GEOMETRY data is flawless, I have looked at the records in SQL developer and all the data is there.
    Any ideas?
    In case you're wondering, I do have reasons for: (i) wanting an explicit column with the SDO_GEOMTRY (serving via WFS), and (ii) not wanting to alter the original table to include the equivalent SDO_GEOMETRY column.
    Cheers,
    M.

    Hi,
    if you are having problems to display your view spatial columns in MapBuilder/MapViewer, you may be missing to register the view information in the metadata (name and spatial columns).
    For example, lets see the following table that simulates your case:
    SQL> desc pci_image;
    Name Null? Type
    GEORID NOT NULL NUMBER
    TYPE VARCHAR2(32)
    GEORASTER MDSYS.SDO_GEORASTER
    -- create a view
    create view pci_img_view (georid,georaster,geor_extents)
    as
    select a.georid,a.georaster,a.georaster.spatialextent
    from pci_image a;
    -- register metadata for view spatial columns (GeoRaster and geometry column)
    insert into user_sdo_geom_metadata
    select 'PCI_IMG_VIEW','GEORASTER.SPATIALEXTENT', diminfo, srid
    from user_sdo_geom_metadata where table_name = 'PCI_IMAGE'
    insert into user_sdo_geom_metadata
    select 'PCI_IMG_VIEW','GEOR_EXTENTS', diminfo, srid
    from user_sdo_geom_metadata where table_name = 'PCI_IMAGE'
    There is no need to index the spatial columns if they have been indexed before.
    Now, if you go in MapBuilder you should see the the view name in the list of geometry tables, and be able to create a theme on column GEOR_EXTENTS (select it on the combo box) and to preview it.
    For the GeoRaster column, currently the view name is not shown on the list of GeoRaster tables in MapBuilder.
    For GeoRaster data, MapBuilder uses the contents of metadata view user_sdo_geor_sysdata, and then it would be needed to register the view contents there. We will talk with Jeffrey to check if there is any problem in registering
    view contents in this metadata view. If the view name and georaster column is registered in user_sdo_geor_sysdata,
    then it should show in MapBuilder. But you can still create a GeoRaster theme for this view using a SQL command, and should be able to preview it in MapBuilder.
    -- create a GeoRaster theme based on view Georaster column.
    insert into user_sdo_themes values (
    'PCI_IMAGE_V_GEOR',
    'View of georaster column',
    'PCI_IMG_VIEW',
    'GEORASTER',
    '<?xml version="1.0" standalone="yes"?>
    <styling_rules theme_type="georaster" raster_id="1" raster_table="RDT_PCI" raster_bands="0,1,2">
    </styling_rules>');
    -- commit changes
    commit;
    Joao

  • How to get the current selected column and row

    Hi,
    A difficult one, how do i know which column (and row would also be nice) of a JTable is selected?
    e.g.
    I have a JButton which is called "Edit" when i select a cell in the JTable and click the button "Edit" a new window must be visible as a form where the user can edit the a part of a row.
    Then the column which was selected in the JTable must be given (so i need to know current column) and then i want the TextField (the one needed to be edited) be active with requestFocus(). So it would be
    pricetextfield.requestFocus();
    Problem now is that i have to click every time in the window the JTextField which was selected in the JTable. I have chosen for this way of editing because my application is multi-user and it would be too difficult for me when everybody did editing directly (catch signals, reload data, etc.).
    My question is how do I know the current column and the current row in a JTable?

    I'm not sure what your mean by the "current" row or column, but the following utility methods return
    which row and column have focus within the JTable.
    public static int getFocusRow(JTable table) {
        return table.getSelectionModel().getLeadSelectionIndex();
    public static int getFocusColumn(JTable table) {
        return table.getColumnModel().getSelectionModel().getLeadSelectionIndex();
    }

  • Preview's PDF text select ignores columns and misses word spaces

    I have a number of scanned pdf newspaper articles that I was attempting to copy the text from. Preview appears to register the existence of columns, as there is a pale blue background between the columns.
    However when I use the text select tool, it completely ignores the column - and just selects across all columns. And when I paste the text into my text editor, it's missing all the spaces between the words, and the font size is always huge.
    Conversely, Adobe reader in XP has no problem selecting by column, and the pasted text is also an exact replication of the original content. I don't know why Preview performs so badly in this regard? Anyone else experience any issues with pdf text select?

    Anyone else experience any issues with pdf text select?
    Yes, and not just recently.
    There is a reason Preview is named, well, preview. It is not an authoring environment and PDFs are not meant to serve in that context either...unless maybe you understand all of inherent the font traps, tricks & tips and how to tune your scanning/OCR software to keep rework to a minimum.
    Scanning PDFs is always tricky, and without the occasional heavy metal to bring to the task, it just seems to be that more problematic.
    Keep trying, but I'd really suggest to look to other tools at this time.

  • Inheritance based on USER column and JPQL based on @ManyToOne column

    I wanted to build a simple inheritence scheme for no other reason than to support a generalized table that I could manipulate in standard libraries and to extend that table with columns that might exist in various customer implementations. In the extra-ordinarily simple example that follows I created a base Parcel class; extend that with a ParcelBean which has a column specific to a user; and extend that further with a wrapper class that will include some Trinidad references that I want to keep completely away from the bean classes. In short, I wanted to put together an inheritence scheme for basic OO reasons, not because of any particular table structure.
    After some thought I figured that the best way to do this might be to use the Single-Table Strategy, especially after I discovered that I could fool the system by using the Oracle USER pseudo-column for my DiscriminatorColumn and use my schema name for the DiscriminatorValue.
    @Entity
    @Table(name = "PARCEL")
    @Inheritance
    @DiscriminatorColumn(name = "USER")
    public class Parcel {
      String parcelPin;
      public Parcel() {
      @Id
      @Column(name = "PARCELPIN", nullable = false)
      public String getParcelPin() {
        return parcelPin;
      public void setParcelPin(String parcelPin) {
        this.parcelPin = parcelPin;
    @Entity
    public class ParcelBean extends Parcel {
      LandUseType luc;
      public ParcelBean() {
      public void setLuc(LandUseType newluc) {
        this.luc = newluc;
      @ManyToOne
      @JoinColumn(name = "LUC")
      public LandUseType getLuc() {
        return luc;
    @Entity
    @DiscriminatorValue("CPC")
    public class ParcelRow extends ParcelBean {
      public ParcelRow() {
      public void doSomething(ActionEvent ae) {
        ; // Trinidad code
    }For a couple of weeks this has been working fine. Right up until I tried to a JPQL like the following:
    "select p from ParcelRow p where p.luc.cpcCode=12"The problem is that TOPLINK will generate SQL that prefixes USER with an alias (something it does not do if there isn't a foreign key reference involved). This won't work because Oracle SQL does not allow aliases on pseudo-columns
    select USER from PARCEL; -- return CPC
    select p.USER from PARCEL p; -- throws ORA-01747: invalid user.table.column specificationSo now I'm in a jam. I can't (read won't if you will) give up on my requirement for inheritence. I have multiple clients with the same basic legacy table with minor variations and I have tens of thousands of lines of code that work on the basic core table properties and I don't want to copy and paste. I could use interfaces, except that I would still have to extend the Beans with my Row classes so that I could add the JSF actionListeners (and other such stuff). I need to be able to select Lists of these Row classes with the JSF methods so that I can expose them as values to JSF/Trinidad/ADF Tables and it break every person pattern I enforce to mix JSF and JPA dependencies in the same class.
    Anyone out there have any ideas?
    Thanks Mark

    Of course a simple fix for this problem would be if the Oracle provider code was smart enough to recognize pseudo columns and to not prefix them with an alias.
    Is there any chance that this might be done before a final release?
    Mark

Maybe you are looking for

  • Can I back up the HDD and an External drive at the same time?

    Hi - I have a 250Gb HDD (tiny!), but I have just bought myself 2 x 2Gb external drives which I have now formatted. I intend to move my complete iTunes library on to 1 of the externals and I want to use the other external as a back-up for both the HDD

  • How To change my Game Center Account's Apple ID?

    Hi, i want to change my Game Center account's Apple ID because i used another apple ID a long time ago and i have a lot of points and of games attached with this account. I want to attach my apple ID (the one wich i use now) with my Game Center accou

  • How do you choose different audio streams?

    If you have an "audio options" menu, and you have the choice between Ac3 and DTS, how would you link the different audio tracks to the buttons in the sub menu. also, how do you link the tracks to the audio button on you dvd players controller? thanks

  • HT2688 How can I add a playlist from one computer to another in my home sharing network?

    I have a playlist set up on my static PC and I would like to transfer it to my Ipod and also my laptop. I have "dragged" it but I deget the "denied" icon. Surely I can do this? any help would be fab! Thanks

  • HBH-IS800 - Volume Too Low?

    I just got the HBH-IS800 Bluetooth earphones, which are a godsend for wireless stereo music. But, the volume on them is much lower than the stock Apple earphones. My iPhone 4 sets the volume to 100% on default, which was the first thing that made me