/* Check to make sure we are connected to the database before allowing access to the home page. If not connected, go connect and initialize; otherwise, welcome the user.\ */ if(!database.connected()) redirect("init.htm"); Dependent Information
namecursor = database.cursor("select name from employee where ssn = " + client.ssn + "", true); namecursor.next();
Current Enrollee:write(namecursor.name);


On this form, you may edit your dependent information.
if (request.ssn == "add") { cursor = database.cursor("select * from dependent"); client.action = "insert"; } else { cursor = database.cursor("select * from dependent where employee_ssn = " + client.ssn + " and ssn = " + request.ssn + ""); cursor.next(); client.action = "update"; } dep_cursor = database.cursor("select * from dep_rel");
} else { write(cursor.ssn); } } else { } } else { Remove } } else { } } else { } } else { } } else { No } } else { } } else { } } else { No } } else { No } } else { } } else { } } else { No } } else { No } } else { } } else { }
Social Security Number: if (client.action == "insert") {
Name (Last, First Middle): if (cursor.name == null) {
Action: Edit
if (cursor.action == "r") { Remove
Birthdate: if (cursor.birthdate == null) {
Relationship:
PCP Name: if (cursor.pcp_name == null) {
PCP Number: if (cursor.pcp_no == null) {
Previously Seen? if (cursor.prev_seen == "yes") { Yes } else { Yes }
if (cursor.prev_seen == "no") { No
OB/GYN Name: if (cursor.obgyn_name == null) {
OB/GYN Number: if (cursor.obgyn_no == null) {
OB/GYN Previously Seen? if (cursor.obgyn_prev_seen == "yes") { Yes } else { Yes }
if (cursor.obgyn_prev_seen == "no") { No
Covered by Medicare? if (cursor.medicare == "yes") { Yes } else { Yes }
if (cursor.medicare == "no") { No
Medicare Number: if (cursor.medicare_no == null) {
Medicaid Number: if (cursor.medicaid_no == null) {
Handicapped? if (cursor.handicapped == "yes") { Yes } else { Yes }
if (cursor.handicapped == "no") { No
Full-Time Student? if (cursor.full_time_student == "yes") { Yes } else { Yes }
if (cursor.full_time_student == "no") { No
School: if (cursor.school == null) {
Date of Graduation: if (cursor.grad_date == null) {

Return to Main Menu