1

I have two filed Price and Cost If Price < Cost I should get an error saying Item Price Should be Greater Item Than Cost I need to created Validation In Oracle Apex

3
  • stackoverflow.com/help/how-to-ask Commented May 15, 2019 at 5:42
  • Have you looked at the documentation/tutorials for creating validations? What have you tried? Commented May 15, 2019 at 5:48
  • I know how to create validation. I am asking how to implement this or write this code. Commented May 15, 2019 at 5:57

2 Answers 2

3

That would be a validation of a "PL/SQL function which returns error text" type.

if :P1_PRICE < :P1_COST then
   return 'Item price should be greater than cost';
end if;
return null;
Sign up to request clarification or add additional context in comments.

Comments

0

You can create two item as like :P0_PRICE and :P0_COST After that you Create a validation of type "Function Body returning Boolean" with source code

BEGIN
 IF :P0_PRICE < :P0_COST THEN
   RETURN true;
 END IF;
  RETURN false;
END;

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.