Results 1 to 5 of 5
  1. #1
    New Lounger
    Join Date
    May 2001
    Posts
    7
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Run-time error '7799' in Access 97

    Anyone have any ideas?

    This is an Intermittent error I am getting with one of our 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.

    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.

    I have not been able to find anything from Microsoft's web site on this error in the support section.

    CODE BEING EXECUTED WHEN IT HAPPENS

    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 FOR QUERY BEING USED:

    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;

  2. #2
    Plutonium Lounger
    Join Date
    Dec 2000
    Location
    Sacramento, California, USA
    Posts
    16,775
    Thanks
    0
    Thanked 1 Time in 1 Post

    Re: Run-time error '7799' in Access 97

    Are some of the fields memo fields? You sometimes run into corruption problems with those. Do you have multiple memo fields in a table? That can cause some weird problems too.

    The error message seems to suggest that you have a record that is exceeding the Access size limit, so another possibility is that you have all your text fields set to 255 (the usual result with a make-table query), which can cause problems even in a single-table query.
    Charlotte

  3. #3
    New Lounger
    Join Date
    May 2001
    Posts
    7
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Run-time error '7799' in Access 97

    Charlotte:
    Here are my table structures:
    Table: tblPeople
    cName Text 50
    bAdministrator? Yes/No 1
    cLANID Text 8

    Table: tblTask
    cTask Text 50
    mDescription Memo -

    Table: tblTime
    cName Text 50 select from tblPeople.cName
    dFridayDate Date/Time 8
    cTask Text 50 select from tblTask.cTask
    nHours Number (Double) 8
    cComments Text 50

    The Query I am having problems uses only the tblTime table.

    The table I have to fix each time the error occurs is the tblTask table.

  4. #4
    Plutonium Lounger
    Join Date
    Dec 2000
    Location
    Sacramento, California, USA
    Posts
    16,775
    Thanks
    0
    Thanked 1 Time in 1 Post

    Re: Run-time error '7799' in Access 97

    What happens if you use the DISTINCTROW keyword in your query to confine it to unique records? Does that change anything?
    Charlotte

  5. #5
    New Lounger
    Join Date
    May 2001
    Posts
    7
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Run-time error '7799' in Access 97

    Charlotte,

    The distint row did not help and I would not have been able to use it anyway for what I am doing. However, I think I have figured out the problem.

    In playing with the dist. row this morning, I noticed that the query worked if opened directly but not through the code. In reviewing the form properties, I noticed that I had some bad data in the sort on field. Once I cleared that out, everything is working again. The bad data appeared to be the same field name over and over again. I have no idea how that got there.

    Thanks for the ideas.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •