Skip to Main Content

Java Development Tools

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Interested in getting your voice heard by members of the Developer Marketing team at Oracle? Check out this post for AppDev or this post for AI focus group information.

add Validation when inserting in ADF table

User_7TK0DAug 23 2022 — edited Aug 23 2022

Hello,
I need some help.
I'm a newbie and I'm using JDeveloper 12.2.1.4.0.
How can I add validation in ADF table when inserting? My requirement was if the status of the person number is NEW and PENDING with same cycle, it will not insert to avoid duplication and it will insert only if the status is already set to PROCESSED
For example,
The UI page
image.pngclicked the create button
image.pngafter inputting the data, when I click save button it should not insert because the person number and the cycle is already existing the table
image.pngimage.png
This is the functionality of the buttons
image.png
Thank you.

This post has been answered by Timo Hahn on Aug 23 2022
Jump to Answer

Comments

Alex Keh-Oracle

It could be a bug. Do you have test case to help us better understand the problem with TimeOfDay that you experience?

mariohik

Sorry for the delay.
I can't use TimeOfDay as in the example below:

var ts1 = new TimeSpan(6, 10, 0);
var ts2 = new TimeSpan(6, 50, 0);


var x = from t in TestTable
where t.DtColumn.Value.TimeOfDay >= ts1
&& t.DtColumn.Value.TimeOfDay <= ts2
select t;


x.Dump();

Instead, I have to run the query separately (hours and minutes):

from t in TestTable
where (t.DtColumn.Value.Hour >= 6 && t.DtColumn.Value.Minute >= 10 )
&& (t.DtColumn.Value.Hour <= 6 && t.DtColumn.Value.Minute <= 50 )
select t

I am attaching a sample table and you can use LinqPad to test the query.
export.txt (130.51 KB)

Alex Keh-Oracle

Thanks for reporting. I filed bug 32388939 to track this issue. We'll take a look at it.

Alex Keh-Oracle
Answer

This bug was fixed, but missed making it into the first Oracle EF Core 5 release. The fix will be part of the next Oracle EF Core 5 release.

Marked as Answer by mariohik · Feb 12 2021
mariohik

Thank you!

1 - 5

Post Details