7 Replies Latest reply: Aug 30, 2013 5:17 AM by user8959800 RSS

    Format values: DB View or anything in ADF ViewObject?

    user8959800

      Hi.

       

      I have a DB table with a field called PERSON_ID, which is the ID of one person.My JDeveloper version is 11.1.1.7.0

      With an Oracle funcion in DB, I pass this ID and get Mr. John Smith Smith ready to show in the application.

       

      Other field in the table is AGE, with a raw simple number.

       

      I need to generate an ADF table, and I need to show the formatted person name and his/her age.

       

      I have tried these two approaches to get the solution:

      • Generate a calculated attribute in the ViewObject, and try to invoke the DB function: obviosly, if this was possible, I did something wrong, because it didn't work. If something like this was possible, it would be the best solution.
      • DB View: This works, but I can't commit data in this application window.
        • Create a DB View with formatted name, age, etc.
        • Map it in an EO and VO
        • Generate an ADF table from this VO
        • When the above form is filled, insert the form data in DB Table.
        • Commit the new row
        • Reload the ADF table.

       

      How can I solve this issue?

       

      Any suggestion is very appreciated

      Thanks in advance. Regards