aldredd
11-22-2004, 05:36 AM
In my database, I have several tables.
Most data is entered into just the one table from the opening page, which is all fine, but sometimes, the user will tick a box which means more info needs to be entered.
When submitted, depending on the 'department' chosen by the user on the first page, the next page will display a number of text forms. These options are pulled off from the database
So on the previous page, they selcted department a), the next page then uses that department code (always a number), then matches that with the possable errors for that department (tblDECodes). These are put into a form as text boxes. The value is the error code, and the name is pulled off the table tblErrorCodes.
tblDECodes tblErrorCodes
DeptID - ErrorCode ErrorCode - Name
1 - 3 1 - damage
1 - 5 2 - missing
2 - 3 3 - Extra
2 - 4
Okay so far..
The user then enters however many there are for each error (often 0) and submits it.
This is where I have problems.
The original data from the first page gets put into the table tblQAuditsHD, but what I need to somehow do, is find out which of the text boxes have had data entered into them - which is a bugger, cos there is no telling what form names there will be, and then enter both the error code, and it's corresponding total into table tblQAuditsDT. And, if that wasn't bad enough, when the data is put into tblQAuditsHd, it's assign it's unique number QAID. When the error codes are put into tblQAuditsDT, it needs to have the QAID assigned to it - entered in that table too.
tblQAuditsHDt
QAID - ErrorCode - Count
565 - 1 - 2
573 - 3 - 1
I hope you're able to help, as I've hit a dead end. :confused:
If you need to view / access the code, db or whatever, let me know, and I'll see what I can do :o)
Many thanks,
David Aldred
Most data is entered into just the one table from the opening page, which is all fine, but sometimes, the user will tick a box which means more info needs to be entered.
When submitted, depending on the 'department' chosen by the user on the first page, the next page will display a number of text forms. These options are pulled off from the database
So on the previous page, they selcted department a), the next page then uses that department code (always a number), then matches that with the possable errors for that department (tblDECodes). These are put into a form as text boxes. The value is the error code, and the name is pulled off the table tblErrorCodes.
tblDECodes tblErrorCodes
DeptID - ErrorCode ErrorCode - Name
1 - 3 1 - damage
1 - 5 2 - missing
2 - 3 3 - Extra
2 - 4
Okay so far..
The user then enters however many there are for each error (often 0) and submits it.
This is where I have problems.
The original data from the first page gets put into the table tblQAuditsHD, but what I need to somehow do, is find out which of the text boxes have had data entered into them - which is a bugger, cos there is no telling what form names there will be, and then enter both the error code, and it's corresponding total into table tblQAuditsDT. And, if that wasn't bad enough, when the data is put into tblQAuditsHd, it's assign it's unique number QAID. When the error codes are put into tblQAuditsDT, it needs to have the QAID assigned to it - entered in that table too.
tblQAuditsHDt
QAID - ErrorCode - Count
565 - 1 - 2
573 - 3 - 1
I hope you're able to help, as I've hit a dead end. :confused:
If you need to view / access the code, db or whatever, let me know, and I'll see what I can do :o)
Many thanks,
David Aldred