Displaying information other than a foreign key in 'interactive reports'

I would be very grateful if someone could help with the following query. I have 2 tables (*Table1* and Table2). Table1 has the following columns:-
Tbl1PrimaryKey, Tbl1Description
Table2 has the following columns:-
Tbl2PrimaryKey, Tbl2Description, Tbl1ForeignKey
Where Tbl1PrimaryKey is the 'primary key' in Table1, Tbl2PrimaryKey is the 'primary key' in Table2 and Tbl1ForeignKey is a 'foreign key' and uses the 'primary key' from Table1.
I would like to create a page which displays the description of Table2 and Table1 on a web page, however, using an 'interactive report' in APEX, the resulting web page displays:-
Tbl2PrimaryKey, Tbl2Description, Tbl1ForeignKey
I would like to change the underlying code to display Tbl1Description instead of the primary key, but I can't get the SQL coding correct. The region source sql code at present is:-
select "Tbl2PrimaryKey",
"Tbl2Description",
"Tbl1ForeignKey"
from "#OWNER#"."Table2"
Any help regarding the above query will be appreciatiated.

Try one of the following in the Source:
in-line query...(My favorite)
select "Tbl2PrimaryKey",
"Tbl2Description",
(select Tbl1Description from Table1 where "Table2"."Tbl1ForeignKey" = Table1.Tbl1PrimaryKey) Tbl1Description
from "#OWNER#"."Table2"
-or-
Classic Join (if Tbl1ForeignKey is NOT NULL)
select "Tbl2PrimaryKey",
"Tbl2Description",
Tbl1Description
from "#OWNER#"."Table2", Table1
where "Table2"."Tbl1ForeignKey" = Table1.Tbl1PrimaryKey
Hope that helps,
Russ

Similar Messages

  • Displaying lauguages other than English

    Hi,
    I am working with Dreamweaver 8 and having problems in
    displaying languages other than English. When i open a page having
    Chinese characters and make some changes to it and save it, it
    gives me the message of using UTF8 fonts. After i click Ok, it
    changes the text into garbage characters and does not show the text
    in preview as well. Before making the changes, i am able to view
    the text in Chinese in Dreamweaver and also in my browser. Any idea
    as to how i can fix this? Your help will be appreciated.
    Thanks,

    Try one of the following in the Source:
    in-line query...(My favorite)
    select "Tbl2PrimaryKey",
    "Tbl2Description",
    (select Tbl1Description from Table1 where "Table2"."Tbl1ForeignKey" = Table1.Tbl1PrimaryKey) Tbl1Description
    from "#OWNER#"."Table2"
    -or-
    Classic Join (if Tbl1ForeignKey is NOT NULL)
    select "Tbl2PrimaryKey",
    "Tbl2Description",
    Tbl1Description
    from "#OWNER#"."Table2", Table1
    where "Table2"."Tbl1ForeignKey" = Table1.Tbl1PrimaryKey
    Hope that helps,
    Russ

  • Finder Methods other than by Primary key

    How should the Finder methods other than by Primary
    key in Container MB be implemented? In Bean class?
    I did some search in archives to no avail.
    Thanks!!
    Sriram

    I think it might be different on different app servers, at least until EJB 2.0 is implemented everywhere. I found a bit of info on the matter:
    http://www.jboss.org/documentation/HTML/ch06s07.html

  • Binding for table produces list for other tables using foreign key and crea

    Using
    software Jdev 11G, WLS 11G, Oracle DB 11G, Windows Vista platform
    technology EJB 3.0, jspx, backing beans, session bean
    I cannot create a namedquery on my secondary table. The method for the column uses the entity object rather than the name and value of the column.
    For instance,
    (Coketruck) table has inventory records(Products) table
    Coketruck has one to many to the Products table
    Products has a many to one to the Coketruck
    I need to return the products from the product table based on the CokeTruck but I cannot create a namedQuery because the method in the Product table is an entity object type instead of a long that I can use to look up all the products based off the column truck_id.
    This is what I was expecting…
    Private Long truckId;
    public Long getTruckId() {
    return truckId;
    public void setTruckId (Long truckId) {
    this. truckId = truckId;
    Instead this is what I have…
    @ManyToOne
    @JoinColumn(name = "TRUCK_ID")
    private Coketruck coketruck;
    this. coketruck = coketruck
    public Coketruck getCoketruck() {
    return coketruck;
    public void set Coketruck (Coketruck coketruck) {
    this. coketruck = coketruck;
    How do I do a query on the Product table to return all the products that are in the coketruck?
    If I do the following it expects for me to pass the Entity Object which I cannot use as search criteria for my find method.
    @NamedQuery(name = "Products.findById", query = "select o from Products o where o.truckId = :truckId")
    On a different note but the same song…
    I noticed that when I look at my Session Bean Data Contols that the coketruck already has a list of the products. I have created a jsp page with a backing bean and have been able to use the namedquery on the coketruck entity to retrieve the productList. Unfortunately I need to sort the products by type and was also not able to find where to perform the work to be able to iterate through the productList to get my desired display. Therefore I started looking at doing another namedquery that would only retrieve the product_type ordering by the truckId.
    Seems I have come full circle… I don’t care what method I have to use to get the info back.
    Any help is greatly appreciated!

    user9005175 wrote:
    Hi!
    I work on an application wich uses a shopping cart stored in a database. The shopping cart uses two tables:
    CART: Holds information common for one shopping cart: the user it is connected to etc.
    - Primary key: CART_ID
    CART_ROW: One row in the cart, e.g. one new product to buy.
    - Primary key: ROW_ID
    - Foreign key: CART_ROW.CART_ID references CART.CART_ID
    From the code the rows in the cart are collected per cart, as is modelled by the foreign key. There exists one more relationship, which we use in the code, but which is not modelled by a foreign key in the database. One row can be dependent on another row, which makes the other row a parent.
    CART_ROW has a column PARENT_ID which references CART_ROW.ROW_ID.
    Should we add a foreign key for PARENT_ID? Or are there any questions to consider when it is a foreign key to the same table?
    I suggest to add foreign key it wont harm the performance (except while on insert when there would be validation for the foreign key). But it would prevent users to insert wrong/corrupt data either through code or directly by loggin in the database.
    A while ago we added indexes, both on ROW_ID and on PARENT_ID. Could the index on PARENT_ID have been harmful, since there is no foreign key?
    Index on parent_id would only be harmful if you do not make use of index after creating it (i.e. there is no query which make use of this index).
    And if you decide to have a foreign key on parent_id then I suggest to have index too on parent_id as it would be helpful atleast when you delete any record in this table.
    Best regards!

  • Interactive alv report......with one table having more than 2 foreign key

    *& Report  ZRAHUL_ALV_SFLIGHT2
    REPORT  zrahul_alv_sflight2 NO STANDARD PAGE HEADING.
    TYPE-POOLS slis.
    DATA: fcat TYPE slis_fieldcat_alv,
          it_fcat TYPE slis_t_fieldcat_alv,
          fcat1 TYPE slis_fieldcat_alv,
          it_fcat1 TYPE slis_t_fieldcat_alv,
          fcat2 TYPE slis_fieldcat_alv,
          it_fcat2 TYPE slis_t_fieldcat_alv,
          lout TYPE slis_layout_alv,
          head TYPE slis_listheader,
          it_head TYPE slis_t_listheader.
    TABLES: SFLIGHT, SCURX, SAPLANE.
    DATA: BEGIN OF it_sflight OCCURS 0,
            carrid TYPE sflight-carrid,      "PK
            connid TYPE sflight-connid,
            fldate TYPE sflight-fldate,
            currency TYPE sflight-currency,        "FK 1
            planetype TYPE sflight-planetype,      "FK 2
          END OF it_sflight.
    DATA: BEGIN OF it_scurx OCCURS 0,
            currkey TYPE scurx-currkey,        "PK 1
            currdec TYPE scurx-currdec,
          END OF it_scurx.
    DATA: BEGIN OF it_saplane OCCURS 0,
            planetype TYPE saplane-planetype,      "PK 2
            seatsmax TYPE saplane-seatsmax,
            tankcap TYPE saplane-tankcap,
            weight TYPE saplane-weight,
          END OF it_saplane.
    SELECTION-SCREEN: BEGIN OF BLOCK blk WITH FRAME TITLE t.
    SELECT-OPTIONS: id FOR it_sflight-carrid,
                    id2 FOR it_sflight-connid.
    SELECTION-SCREEN END OF BLOCK blk.
    INITIALIZATION.
      t = 'enter required criterias'.
      lout-zebra = 'X'.
    START-OF-SELECTION.
      SELECT * FROM sflight INTO CORRESPONDING FIELDS OF TABLE it_sflight
                WHERE carrid IN id AND connid IN id2.
    END-OF-SELECTION.
    ****FCAT F0R IT_SFLIGHT
      fcat-col_pos = 1.
      fcat-tabname = 'IT_SFLIGHT'.
      fcat-fieldname = 'CARRID'.
      fcat-outputlen = 10.
      fcat-seltext_m = 'PLANE ID'.
      APPEND fcat TO it_fcat.
      CLEAR fcat.
      fcat-col_pos = 2.
      fcat-tabname = 'IT_SFLIGHT'.
      fcat-fieldname = 'CONNID'.
      fcat-outputlen = 10.
      fcat-seltext_m = 'CONN ID'.
      APPEND fcat TO it_fcat.
      CLEAR fcat.
      fcat-col_pos = 3.
      fcat-tabname = 'IT_SFLIGHT'.
      fcat-fieldname = 'FLDATE'.
      fcat-outputlen = 10.
      fcat-seltext_m = 'FLDATE'.
      APPEND fcat TO it_fcat.
      CLEAR fcat.
      fcat-col_pos = 4.
      fcat-tabname = 'IT_SFLIGHT'.
      fcat-fieldname = 'CURRENCY'.
      fcat-outputlen = 10.
      fcat-seltext_m = 'CURRENCY'.
      APPEND fcat TO it_fcat.
      CLEAR fcat.
      fcat-col_pos = 5.
      fcat-tabname = 'IT_SFLIGHT'.
      fcat-fieldname = ';PLANETYPE'.
      fcat-outputlen = 10.
      fcat-seltext_m = 'PLANETYPE'.
      APPEND fcat TO it_fcat.
      CLEAR fcat.
    *****GRID DISPLAY
      CALL FUNCTION 'REUSE_ALV_GRID_DISPLAY'
       EXPORTING
        I_INTERFACE_CHECK                 = ' '
        I_BYPASSING_BUFFER                = ' '
        I_BUFFER_ACTIVE                   = ' '
        i_callback_program                = 'ZRAHUL_ALV_SFLIGHT2'
        I_CALLBACK_PF_STATUS_SET          = ' '
         i_callback_user_command           = 'CLICK'
         i_callback_top_of_page            = 'HEADER'
        I_CALLBACK_HTML_TOP_OF_PAGE       = ' '
        I_CALLBACK_HTML_END_OF_LIST       = ' '
        I_STRUCTURE_NAME                  =
        I_BACKGROUND_ID                   = ' '
         i_grid_title                      = 'GRID 1'
        I_GRID_SETTINGS                   =
         is_layout                         = lout
         it_fieldcat                       = it_fcat
        IT_EXCLUDING                      =
        IT_SPECIAL_GROUPS                 =
        IT_SORT                           =
        IT_FILTER                         =
        IS_SEL_HIDE                       =
        I_DEFAULT                         = 'X'
        I_SAVE                            = ' '
        IS_VARIANT                        =
        IT_EVENTS                         =
        IT_EVENT_EXIT                     =
        IS_PRINT                          =
        IS_REPREP_ID                      =
        I_SCREEN_START_COLUMN             = 0
        I_SCREEN_START_LINE               = 0
        I_SCREEN_END_COLUMN               = 0
        I_SCREEN_END_LINE                 = 0
        I_HTML_HEIGHT_TOP                 = 0
        I_HTML_HEIGHT_END                 = 0
        IT_ALV_GRAPHICS                   =
        IT_HYPERLINK                      =
        IT_ADD_FIELDCAT                   =
        IT_EXCEPT_QINFO                   =
        IR_SALV_FULLSCREEN_ADAPTER        =
      IMPORTING
        E_EXIT_CAUSED_BY_CALLER           =
        ES_EXIT_CAUSED_BY_USER            =
        TABLES
          t_outtab                          = it_sflight
      EXCEPTIONS
        PROGRAM_ERROR                     = 1
        OTHERS                            = 2
      IF sy-subrc <> 0.
    MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
            WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
      ENDIF.
    *&      Form  header
          text
    FORM header.
      CLEAR it_head.
      head-typ = 'H'.
      head-info = 'KINGFISHER'.
      APPEND head TO it_head.
      head-typ = 'S'.
      head-key = 'KEY'.
      head-info = 'AIRLINES'.
      APPEND head TO it_head.
      CALL FUNCTION 'REUSE_ALV_COMMENTARY_WRITE'
        EXPORTING
          it_list_commentary       = it_head
         i_logo                   = 'KING_LOGO'
      I_END_OF_LIST_GRID       =
      I_ALV_FORM               =
    ENDFORM.                    "header
    *&      Form  CLICK
          text
         -->OK         text
         -->SEL        text
    FORM click USING ok TYPE sy-ucomm
                     sel TYPE slis_selfield.
      CLEAR it_fcat.
      CASE ok.
        WHEN '&IC1'.
    ********SAPLANE RELATION
          READ TABLE it_sflight INDEX sel-tabindex.
          SELECT * FROM saplane INTO CORRESPONDING FIELDS OF TABLE it_saplane WHERE planetype = it_sflight-planetype.
          fcat-col_pos = 1.
          fcat-tabname = 'IT_SAPLANE'.
          fcat-fieldname = 'PLANETYPE'.
          fcat-outputlen = 10.
          fcat-seltext_m = 'TYPE OF PLANE'.
          APPEND fcat TO it_FCAT.
          CLEAR fcat.
          fcat-col_pos = 2.
          fcat-tabname = 'IT_SAPLANE'.
          fcat-fieldname = 'SEATSMAX'.
          fcat-outputlen = 10.
          fcat-seltext_m = 'MAX SEATS'.
          APPEND fcat TO it_FCAT.
          CLEAR fcat.
          fcat-col_pos = 3.
          fcat-tabname = 'IT_SAPLANE'.
          fcat-fieldname = 'TANKCAP'.
          fcat-outputlen = 10.
          fcat-seltext_m = 'FUEL TANK CAPACITY'.
          APPEND fcat TO it_FCAT.
          CLEAR fcat.
          fcat-col_pos = 4.
          fcat-tabname = 'IT_SAPLANE'.
          fcat-fieldname = 'WEIGHT'.
          fcat-outputlen = 10.
          fcat-seltext_m = 'WEIGHT F PLANE'.
          APPEND fcat TO it_FCAT.
          CLEAR fcat.
          CALL FUNCTION 'REUSE_ALV_GRID_DISPLAY'
           EXPORTING
      I_INTERFACE_CHECK                 = ' '
      I_BYPASSING_BUFFER                = ' '
      I_BUFFER_ACTIVE                   = ' '
             i_callback_program                = 'ZRAHUL_ALV_SFLIGHT2'
      I_CALLBACK_PF_STATUS_SET          = ' '
      I_CALLBACK_USER_COMMAND           = ' '
             i_callback_top_of_page            = 'HEADER'
      I_CALLBACK_HTML_TOP_OF_PAGE       = ' '
      I_CALLBACK_HTML_END_OF_LIST       = ' '
      I_STRUCTURE_NAME                  =
      I_BACKGROUND_ID                   = ' '
             i_grid_title                      = 'GRID 2'
      I_GRID_SETTINGS                   =
             is_layout                         = LOUT
             it_fieldcat                       = IT_FCAT
      IT_EXCLUDING                      =
      IT_SPECIAL_GROUPS                 =
      IT_SORT                           =
      IT_FILTER                         =
      IS_SEL_HIDE                       =
      I_DEFAULT                         = 'X'
      I_SAVE                            = ' '
      IS_VARIANT                        =
      IT_EVENTS                         =
      IT_EVENT_EXIT                     =
      IS_PRINT                          =
      IS_REPREP_ID                      =
      I_SCREEN_START_COLUMN             = 0
      I_SCREEN_START_LINE               = 0
      I_SCREEN_END_COLUMN               = 0
      I_SCREEN_END_LINE                 = 0
      I_HTML_HEIGHT_TOP                 = 0
      I_HTML_HEIGHT_END                 = 0
      IT_ALV_GRAPHICS                   =
      IT_HYPERLINK                      =
      IT_ADD_FIELDCAT                   =
      IT_EXCEPT_QINFO                   =
      IR_SALV_FULLSCREEN_ADAPTER        =
    IMPORTING
      E_EXIT_CAUSED_BY_CALLER           =
      ES_EXIT_CAUSED_BY_USER            =
            tables
              t_outtab                          = IT_SAPLANE
    EXCEPTIONS
      PROGRAM_ERROR                     = 1
      OTHERS                            = 2
          IF sy-subrc <> 0.
    MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
            WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
          ENDIF.
    *******SCURX RELATION
                    CLEAR: IT_FCAT2,IT_FCAT.
                    READ TABLE IT_SFLIGHT INDEX SEL-TABINDEX.
                      SELECT * FROM SCURX INTO CORRESPONDING FIELDS OF TABLE IT_SCURX WHERE CURRKEY = IT_SFLIGHT-CURRENCY.
                      FCAT2-COL_POS = 1.
                      FCAT2-TABNAME = 'IT_SCURX'.
                      FCAT2-FIELDNAME = 'CURRKEY'.
                      FCAT2-OUTPUTLEN = 15.
                      FCAT2-SELTEXT_M = 'CURRENCY'.
                      APPEND FCAT2 TO IT_FCAT2.
                      CLEAR FCAT2.
                      FCAT2-COL_POS = 2.
                      FCAT2-TABNAME = 'IT_SCURX'.
                      FCAT2-FIELDNAME = 'CURRDEC'.
                      FCAT2-OUTPUTLEN = 15.
                      FCAT2-SELTEXT_M = 'CURRENCY DEC'.
                      APPEND FCAT2 TO IT_FCAT2.
                      CLEAR FCAT2.
                      CALL FUNCTION 'REUSE_ALV_GRID_DISPLAY'
                       EXPORTING
                        I_INTERFACE_CHECK                 = ' '
                        I_BYPASSING_BUFFER                = ' '
                        I_BUFFER_ACTIVE                   = ' '
                         I_CALLBACK_PROGRAM                = 'ZRAHUL_ALV_SFLIGHT2'
                        I_CALLBACK_PF_STATUS_SET          = ' '
                        I_CALLBACK_USER_COMMAND           = ' '
                         I_CALLBACK_TOP_OF_PAGE            = 'HEADER'
                        I_CALLBACK_HTML_TOP_OF_PAGE       = ' '
                        I_CALLBACK_HTML_END_OF_LIST       = ' '
                        I_STRUCTURE_NAME                  =
                        I_BACKGROUND_ID                   = ' '
                         I_GRID_TITLE                      = 'GRID 3'
                        I_GRID_SETTINGS                   =
                         IS_LAYOUT                         = LOUT
                         IT_FIELDCAT                       = IT_FCAT2
                        IT_EXCLUDING                      =
                        IT_SPECIAL_GROUPS                 =
                        IT_SORT                           =
                        IT_FILTER                         =
                        IS_SEL_HIDE                       =
                        I_DEFAULT                         = 'X'
                        I_SAVE                            = ' '
                        IS_VARIANT                        =
                        IT_EVENTS                         =
                        IT_EVENT_EXIT                     =
                        IS_PRINT                          =
                        IS_REPREP_ID                      =
                        I_SCREEN_START_COLUMN             = 0
                        I_SCREEN_START_LINE               = 0
                        I_SCREEN_END_COLUMN               = 0
                        I_SCREEN_END_LINE                 = 0
                        I_HTML_HEIGHT_TOP                 = 0
                        I_HTML_HEIGHT_END                 = 0
                        IT_ALV_GRAPHICS                   =
                        IT_HYPERLINK                      =
                        IT_ADD_FIELDCAT                   =
                        IT_EXCEPT_QINFO                   =
                        IR_SALV_FULLSCREEN_ADAPTER        =
                      IMPORTING
                        E_EXIT_CAUSED_BY_CALLER           =
                        ES_EXIT_CAUSED_BY_USER            =
                        TABLES
                          t_outtab                          = IT_SCURX
                      EXCEPTIONS
                        PROGRAM_ERROR                     = 1
                        OTHERS                            = 2
                      IF sy-subrc <> 0.
    MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
            WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
                      ENDIF.
      ENDCASE.
    ENDFORM.                    "click
    this program runs fine when one navigation is used......but when both the foreign keys come in picture then its shows sequencialy...cant we jump directly to the third one which i require....
    plz guide me.thank u.

    in short i want help on table having multiple foreign keys....and how to navigate in this when working on ALV reports.....
    its easy when using interactive reports by using sy-cucol and sy-curow.....
    reply asap.
    thank u in advance.

  • Calendar information other than iCloud is not showing in Notification center from Mails such as Gmail, Exchange, Yahoo

    Hi,
    After iOS 6 update on iPhone 4S I'm unable to see any information on Notification Center regarding any calendar information from mail boxes such as Gmail, Yahoo, Exchange server etc. But, calendar information is available only from iCloud mail box.
    Please help me to get the calendar information in Notification center from mail boxes other than iCloud too.
    Regards,
    Srini

    Read thier own support document on the subject then
    http://support.apple.com/kb/TS1795
    This document was written as an answer to all those who complained about it as paying MobileMe users
    They ignored us then and when MobileMe became iCloud they ignored us again, and just carried on with a system that will not update the e-mail read status across all devices
    That's how it works,   and like you 1000's of loyal Apple users cant believe it either but there you go

  • Link to other pages of rows in APEX Interactive Report

    In my Interactive Report I would like to add a way to click on page results other than just clicking the > to advance to the next set of results.  I have my rows per page set to 15 by default and would like to keep it that way, but want a way to add links to page 4 or page 5 or page 10 as well.  Has anyone done that before, and if so ideas would be greatly appreciated.  I need to keep my rows per page to 15 because of parameters I send to another page, so increasing the rows per page is not an option. Thanks.

    Hi,
    The next button in your pagination fires a javascript function:
    gReport.navigate.paginate('pgR_min_row=16max_rows=15rows_fetched=15')
    You can create a page button or link containing that javascript function. Replace the number 16 by the rownumber you want to start your result set.
    Kind regards,
    Vincent Deelen

  • Easy way to display lookup value of a foreign key reference vs value itself

    I've figured out how to do this for a Form
    http://www.dba-oracle.com/htmldb/t_lov_list_values_master_parent_child.htm
    ...but not for a report which lists the data row by row.
    Given table Centre with the following columns:
    ID
    Name
    Department_ID
    and given table Department with the following columns:
    ID
    Name
    When the report runs on the Centre table it simply queries ID, Name and Department_ID from the database, and then displays each column as is.
    Instead of displaying the Department_ID from the Centre table (which is a number and not very informational), how can I make it display the Name from the department table?
    I have lots of other similar fields which need to be displayed in this way so I'm hoping there isn't a ton of configuration/coding I need to do.

    Hi,
    Try report query
    SELECT a.id,
      a.name,
      b.name dept_name
    FROM centre a,
      department b
    WHERE a.department_id = b.idBr,Jari

  • JTree: displaying something other than default toString

    Ahoy. I'm working on displaying the structure of some complex objects using a jtree. (Just displaying at the moment, not editing).
    I've chosen to do this at the moment by making the structure itself implement TreeModel, but I could just as well use a DefaultTreeModel.
    My structure contains Lists of other objects. Since I've overridden toString() in those objects, they display fine, but the list that contains them (and forms the parent node) displays the default toString of the ArrayList (or whatever), listing the contents in square brackets.
    The kludge I've done for now is to subclass ArrayList with my own "LabeledList" which takes a label in its constructor and returns it for toString(). This works, but isn't ideal.
    How am I supposed to do it? All I can find is "Sometimes, it is not feasible to override toString; in such a scenario you can override the convertValueToText of JTree to map the object from the model into a string that gets displayed." at http://download.oracle.com/docs/cd/E17409_01/javase/tutorial/uiswing/components/tree.html. This is in the JTree itself, not the model and I don't see how I can do this and keep the view separate from the model. Am I supposed to do something like this, in the JPanel or watever class:
    JTree tree = new JTree() {
      String convertValueToText(Object obj) {
        if(obj instanceof List<?>)
          //work out what I want to display somehow
        else
          super(obj);
    }That seems even worse than what I've already done. I'm kind of confused.

    Sounds like a job for a custom renderer. The JTree tutorial shows an example of one.

  • Preview pane displays message other than highlighted in the mailbox list

    After deleting some messages in my mailbox I've noticed that when I highlight a message, I sometimes see a completely different one in the preview pane (usually it's an earlier message a few days/dozens of messages old). The headers (date/sender/subject etc) in the preview pane do not match same fields in the highlighted line of mailbox contents (top pane in my case). When I double-click the message in the list to open it, it opens the window with a correct title (subject), correct sender's thumbnail image, but wrong headers and contents (same one that was previewed, not the one I want).
    As a result I can't access some of the messages at all through mail.app - though I see they are there and luckily can still read them through mail web access. This only happens with a limited number of selected messages that I can't access permanently. I get about 50 messages a day, and so far have noticed this with 6 or 8.
    Logging off/on, restarting mail.app and the system, emptying trash folders and similar routines don't seem to help.
    Any clues?..

    I'm a little surprised that you've ended up with duplicates. Those messages would have been there prior to re-indexing just that now you can see them. It suggests to me that something has happened some time ago with Mail which has resulted in the same messages being retrieved from the server a second time because it had lost the record of having retrieved them initially. Perhaps there has been some sort of failure with your Mac at the time it was downloading messages. Does that seem likely ???... The originals never got added to the index and now that you've rebuilt the index it has revealed them. No big deal as you say just the hassle of having to identify and delete them.
    Chris
    Message was edited by: 2point5

  • Displaying something other than a list in a JComboBox drop down section

    Dear all,
    i'd like to be able to put a JTree into a JComboBox drop down section, or at least appear to have done this. has anyone done this or have an idea how this might be achieved?
    Cheers,
    Matt

    Sounds like a job for a custom renderer. The JTree tutorial shows an example of one.

  • Set blanks to display something other than a # sign in queries

    Is there a transaction I can use to set the value i want to see if the field is blank?  right now it shows # and I would like to see nothing.

    Hi,
    Option 1:
    Program SAPLRRSV for BEx:
    Modify the text u2018Not Assignedu2019 for system message 027 to u2018 u2018 . This is a global change and it affects all reports.
    Option 2: (Works only with WAD, Version 3.X)
    In the HTML code, add a tag u2018MODIFY_CLASSu2019 and attach a custom class with the change to suppress u201C#u2019 / u2018Not Assignedu2019 values for chars. Create the custom class with u2018CL_RSR_WWW_MODIFY_TABLEu2019 as super class.
    The methods from class u2018CL_RSR_WWW_MODIFY_TABLEu2019 are copied to the custom class. The method u2018CHARACTERISTIC_CELLu2019 should be redefined.
    Put the following piece of code in the method.
    method CHARACTERISTIC_CELL.
    if I_CHAVL = '#'.
    C_CELL_CONTENT = '&nbsp'.
    endif.
    endmethod.
    Please go through the document 'How to hide a column in your web query with the table interface'. You can search for it in SDN.
    Regards,
    Murali.

  • How To Display Bi-Weekly Quota Accruals Other Than Using PT50?

    Is there a t-code or report within SAP that will allow me to see how much Absence Quota is generated each pay period for an employee?  I know I can see this information when I access PT50. However, I would like to know if I can display how much vacation and sick / illness time per pay period an employee(s) generates.
    When I run time eval and an employee's quota buckets are updated, where can I view the information other than going to PT50?
    Thanks,

    If it is HR user try PT_BAL00 but rememberu2026the period on the report would be months because you would have mostly used monthly period parameter for time calendar. Say for example if you run the report for the month you wonu2019t be able to identify which sick/vac time belongs to which pay period. So you have to run the report with pay period dates to get right out put - one period at a time.
    If it is payroll user or employee, then try to use below recommendation:
    >Create two wagetypes Vac time earned and Sick time earned
    >In time eval whenever the vac and sick time is calculated, during update of Quota, please generate these 2 wagetypes based   the quota type. you can use ADDZL.
    >In payroll read these wagetypes from ZL and store it. So your reporting would be from RT not time cluster.
    >This will help you to use payroll reports to pull out data based on pay periods. I strongly recommend this because user would be comfortable using wagetype reports and it would be easy for reporting. Even you can display these wagetypes in paystub
    Edited by: Amosha on Nov 16, 2010 11:24 AM

  • Does a foreign key have to be a primary key

    Hey all.I was checking on the database code written by sambapos.To my surprise, I found a foreign key that is not a primary key anywhere.
    Is that possible?
    If, so why?
    I am really astonished.

    Limitations and Restrictions
    A foreign key constraint does not have to be linked only to a primary key constraint in another table; it can also be defined to reference the columns of a UNIQUE constraint in another table.
    When a value other than NULL is entered into the column of a FOREIGN KEY constraint, the value must exist in the referenced column; otherwise, a foreign key violation error message is returned. To make sure that all values of a composite foreign key constraint
    are verified, specify NOT NULL on all the participating columns.
    FOREIGN KEY constraints can reference only tables within the same database on the same server. Cross-database referential integrity must be implemented through triggers. For more information, see
    CREATE TRIGGER (Transact-SQL).
    FOREIGN KEY constraints can reference another column in the same table. This is referred to as a self-reference.
    A FOREIGN KEY constraint specified at the column level can list only one reference column. This column must have the same data type as the column on which the constraint is defined.
    A FOREIGN KEY constraint specified at the table level must have the same number of reference columns as the number of columns in the constraint column list. The data type of each reference column must also be the same as the corresponding column in the column
    list.
    The Database Engine does not have a predefined limit on either the number of FOREIGN KEY constraints a table can contain that reference other tables, or the number of FOREIGN KEY constraints that are owned by other tables that reference a specific table.
    Nevertheless, the actual number of FOREIGN KEY constraints that can be used is limited by the hardware configuration and by the design of the database and application. We recommend that a table contain no more than 253 FOREIGN KEY constraints, and that it
    be referenced by no more than 253 FOREIGN KEY constraints.
    FOREIGN KEY constraints are not enforced on temporary tables.
    If a foreign key is defined on a CLR user-defined type column, the implementation of the type must support binary ordering. For more information, see
    CLR User-Defined Types.
    A column of type varchar(max) can participate in a FOREIGN KEY constraint only if the primary key it references is also defined as type
    varchar(max).
    Read this article
    http://msdn.microsoft.com/en-us/library/ms189049.aspx
    Regards, Ashwin Menon My Blog - http:\\sqllearnings.com

  • Error when sorting foreign key fields in a view

    Hello all
    I created a view and links to other views, and then created a table. In the table I put different attributes from the view and the views it is linked to. When I click the sort ascending or descending button in a column attribute that is in the original view, everything works fine. However if I click the same arrow button for a different column, one that is in a linked view, I get this error message.
    Definition OnlineTerminalId of type Attribute is not found in ObjektiView1.
    I do not understand why this does not work. It shows the values inside these linked views just fine. I did change names of some attributes in the database but I had the problem before then, and after I changed them all back so I doubt that is the issue.
    If anyone can help I would be much obliged

    Dino2dy wrote:
    Hmm, what I did is slightly different, but what my way does is give me the ability to create forms that change automatically when I click a row in a table, which I thought would be useful. I could do it your way too but I would have to do everything again from the beginning, which is something I am trying to avoid. There should be a way to fix this problem this way, as it would be kind of stupid to be able to show the data in the table but just not be able to sort or filter by it.You can still accomplish this by relating the combined VO with your children VOs using View Links, same as what you are doing now.
    Also that view would be HUGE as it is a single table that is connected to a lot of other tables via foreign keys, so my single view would cover 10 tables.Not necessarily. You don't have to include all Entities in your combined VO - just those that you want their attributes displayed on your table.
    Nick

Maybe you are looking for

  • Logical database in sd

    hi experts,    i need standard LDB's  related to the tables of sd, mm and fi... can anyone help regarding this.....

  • Link to a SAP transaction in the body mail using SO_NEW_DOCUMENT_SEND_API1

    Hi everyone, Is it possible to set a link to a text in the body of a mail sent by SO_NEW_DOCUMENT_SEND_API1, in order to navigate to a SAP transaction? Example: Body (in sbwp): Distribution done. Click  here for going to transfer program. And the lin

  • VerifyError

    I'm switching from jdk1.3 to 1.4.1_01 and I'm getting a java.lang.VerifyError when I dynamically load a class into my own Classloader and then try to access the Constructor. Class guiClass = myLoader.loadClass(className); Constructor constr = guiClas

  • Rt.jar in applet tag

    Hello, I'm trying to create an applet that include a few swing classes. From what I have read, the client needs to download the rt.jar file for the applet to access the swing classes. I'm trying to figure out how to include this jar file in the apple

  • Info on ABAP

    Hello All, I have learned ABAP programming under the R/3 environment. I do not have  exposure the SAP netweaver. I would like to know the difference in ABAP programming under both these environments. Is what ever i have learnt under R/3 obsolete, how