Discussion Locked

MS Access 97 -- Run-time error '7799'

0 helpful
11 replies
Closed to new repliesThis discussion is closed. It stays readable, but it takes no new replies.

This is an Intermittent error that is occuring with one of my databases. It appears to be caused by some type of corruption in some records of the task table which is a validation table for the time table task field. When this occurs, I have to identify the time records which contains the bad task value, create a new task record for the same value, switch all existing time entries with this task value over to the new task record and then delete the old task record.

Compress and Repair do not fix this problem, exporting the entire task table to a text file and re-importing it back in does not seem to help either.

The problem has re-occurred on several records and reciently begin occuring on new records added to the task table.COMPLETE ERROR MESSAGE
----------------------

Run-time error '7799'
This form or report is based on a query that exceed the limit for data in a single record.
Exclude any unnecessary fields from the query or change some of the field types to memo in the original tables.

CODE THAT IS EXECUTING
-----------------------
Private Sub cmdViewEditYourTimeLog_Click()

If IsNull(Forms![frmMain]![cbxDateToSelect]) Then
'DoCmd.OpenQuery "qryYourTimeLogAllDates",
acViewNormal, acEdit
DoCmd.OpenForm "frmEntry",
acNormal, "qryYourTimeLogAllDates"
Else
'DoCmd.OpenQuery "qryYourTimeLogForDate",
acViewNormal, acEdit
>>> DoCmd.OpenForm "frmEntry",
acNormal, "qryYourTimeLogForDate"
End If
End Sub

SQL FROM QUERY
---------------
SELECT tblTime.dFridayDate, tblTime.cTask, tblTime.nHours, tblTime.cName, tblTime.cComments
FROM tblTime
WHERE (((tblTime.dFridayDate)=[Forms]![frmMain]![cbxDateToSelect]) AND ((tblTime.cName)=[Forms]![frmMain]![cCurrentUser]))
ORDER BY tblTime.cTask;

11 replies

by msmac67

As the error message indicates,the "comment" field type should be set to "memo" in your table. It seems that is the issue. Check the table design.

by msmac67

As the error message indicates,the "comment" field type should be set to "memo" in your table. It seems that is the issue. Check the table design.

by is

wedwards,

You need to try to give a little more information to try to help with troubleshooting this. Do you know when this is occurring? You may want to see if the user is selecting more than one date, that could cause a problem if you are allowing multiple selections in a list or combo box. If that is not the problem, need to know more about when it is occurring, what is the user selecting when the error occurs?
Another solution that seems to work for a lot of Access problems is to create a new empty database and import all of your tables, fields, queries, reports and modules/macros. This gets rid of some of the garbage that even the compact and repair do not.
One additional step that you can take would be to copy the structure of your table and do an append query with all of your original data, that should validate it against your data types.

Good Luck. Hope one of these ideas help.

by wedwards

Multiple dates are not possible,

Copying everything to another database, exporting the data to a text file and bringing it back in, do not work.

This discussion is closed to new replies.