0
votes

APEX version 4.2.6.00.03

I have a Master/ Detail table. But I need to vaildate the detail table against the Master tables dates. Currently I use a PL/SQL expression below to validate against each the start_date and end_date in the master form. But this is done on submit. This is fine for the master form as only one instance.

CASE WHEN :Master_END_DATE >= :Master_Start_DATE OR
     :Master_END_DATE is NULL THEN TRUE
     ELSE FALSE
 END;

But in the detail there could be upto 20+ rows. So some type of live check/onchange validation. But in the tabular detail form you can not access any of the items from with a dynamic action.

  • Detail_Start_date >= Master_start_Date
  • Detail_Start_date <= Master_End_Date
  • Detail_End_date >= Master_start_Date
  • Detail_date <= Master_End_Date
  • Detail_Start_date >= Detail_End_date
  • Detail_End_date <= Detail_Start_Date

Please see below a snapshot of the form enter image description here

Is this even possible many thanks

1

1 Answers

2
votes

You can add a class to your Tabular Form Columns in Tabular Form:

Edit your columnAdd a class

for the sake of this example I assign "xDate" class to my column. You should assign a class name to each of your column.

Then you create a Dynamic Action (for each class: startDate/endDate, in my case I create one for my column):

enter image description here

enter image description here

If you just need to make some validations with the fields you have in the screen you probably can make them with js only but that depend of what you want/need.

Hope it helps.