Forum Stats

  • 3,767,980 Users
  • 2,252,736 Discussions
  • 7,874,399 Comments

Discussions

Oracle Forms question

user10991018
user10991018 Member Posts: 145 Blue Ribbon
edited Oct 22, 2021 1:48PM in Forms

Hi I have a requirement for eg.

i have multi tab block one tab for dept and another is for EMP for eg.

when tab changed then the emp block will populate with data.

i set emp block property where clause is to execute where deptno=:parameter.deptno.

emp block shows multiple records in grid form for that deptno.


but i want to mask the null values with None

how to do in which trigger i can write.

i dont want to update the columns so i am using the non db items

and set synchronize property to db item name.

please advise thanks very much


right now the data is as below

deptno Empno ename startdate

10 101 test 2021-10-20

10 102 null null

10 103 null null


but i am looking the data to be

deptno Empno ename startdate

10 101 test 2021-10-20

10 102 None None

10 103 None None

thanks

Answers

  • Marwim
    Marwim Member Posts: 3,647 Gold Trophy

    The easiest way might be a view v_emp with

    SELECT NVL(ename,'none') ename

          ,NVL(TO_CHAR(startdate,'yyyy-mm-dd'),'none') startdate

          ,empno

          , ...

    FROM   emp

    DML on this view could be handled by Instead Of Triggers