Databases Reference
In-Depth Information
<Attr Name="_DBObjectName" Value="HR.DEPT"/>
</DesignTime>
<AttrArray Name="Attributes">
<Item Value=
"com.empdirectory.model.entity.DeptEO.Dname"/>
</AttrArray>
</Key>
Have a go hero - compare the attributes
For the irst ime, we have learned about the validaions in ADF. So it's ime for you to
create your own validaion for the EmpEO and DeptEO enity objects. Add validaions
for the following business scenarios:
1. Coninue with the creaion of the uniqueness check for the department name in
the DeptEO.xml ile.
2. The salary of the employees should not be greater than 1000. Display the following
message if otherwise:
Please enter Salary less than 1000.
3. Display the message invalid date if the employee's hire date is after 10-10-2001.
4. The length of the characters entered for Dname of DeptEO.xml should not be
greater than 10.
5. The locaion of a department can only be NEWYORK , CALIFORNIA , or CHICAGO .
6. The department name should always be entered in uppercase. If the user enters a
value in lowercase, display a message.
7. The salary of an employee with the MANAGER job role should be between 800 and
1000. Display an error message if the value is not in this range.
8. The employee name should always start with an uppercase leter and should end
with any character other than special characters such as : , ; , and _ .
9. Ater creaing all the validaions, check the code and tags generated in the enity's
XML ile for each of the aforemenioned validaions.
Groovy expression
ADF Business Components uilize Groovy expressions to support scriping. Groovy is
an open source, Java-like scriping language that can be stored in an XML deiniion ile.
For instance, the atribute name for the employee name Ename can directly be used in
a Groovy expression to represent the value of the Ename atribute.
 
Search WWH ::




Custom Search