I have design a form employees all things are going fine.I have entered data from form ,all the field are getting write value except departmentID no value is assign to this field in the table,y?.I have not mention this field in the form as it is not required also this field is foreign key in the employee table.I have assign one to many relationship between employee and department table.kindly help me.
One-to-many between Employee and department? That means an employee can be in more than one department.
I suspect what you want is a One-to-many relationship between Department and Employee, and then the Employee.Department_ID field is certainly necessary, must be included on the form (unless you want a default department), and is not going to populate itself.
How would the database know what department the employee is in? You have to include that on your form.