Results 1 to 10 of 10
  1. #1
    Helen Roberts is offline Novice
    Windows 10 Access 2007
    Join Date
    Jul 2016
    Posts
    5

    Disappearing Queries

    I am very frustrated as I cannot find any of my old saved queries. I am not a whiz at database so am unsure about re-creating them. I have all my shop stock on a database which I have had since the 1990s. It has worked perfectly for all these years, but since I downloaded Windows 10 I can't find and run all my stockbook queries which give me my figures for the accountant. Please help ........ thank you in advance .......

  2. #2
    ranman256's Avatar
    ranman256 is online now VIP
    Windows Vista Access 2010 32bit
    Join Date
    Apr 2014
    Location
    Kentucky
    Posts
    9,521
    Did you check if the sort order of the queries has changed?
    They could be there but not in the order you think.
    But if you did a search using the search bar, and they are missing, then that is a mystery.

  3. #3
    orange's Avatar
    orange is online now Moderator
    Windows 10 Access 2010 32bit
    Join Date
    Sep 2009
    Location
    Ottawa, Ontario, Canada; West Palm Beach FL
    Posts
    16,716
    Give us more info.
    You have no queries?
    I have all my shop stock on a database
    Tell us about your 90's database--before and after Windows 10.
    We need some context to assist.

    You do have a backup, right?

  4. #4
    Helen Roberts is offline Novice
    Windows 10 Access 2007
    Join Date
    Jul 2016
    Posts
    5
    Quote Originally Posted by ranman256 View Post
    Did you check if the sort order of the queries has changed?
    They could be there but not in the order you think.
    But if you did a search using the search bar, and they are missing, then that is a mystery.

    The only way I can seem to find any queries is in the tab "database tools" under "database documenter" - I may be a little stupid but I can't seem to access any of the queries to run them.

  5. #5
    Helen Roberts is offline Novice
    Windows 10 Access 2007
    Join Date
    Jul 2016
    Posts
    5
    Quote Originally Posted by orange View Post
    Give us more info.
    You have no queries?

    Tell us about your 90's database--before and after Windows 10.
    We need some context to assist.

    You do have a backup, right?
    Hi, yes I have a backup but it has been worked on since I backed it up. I am a little ignorant with database and am not sure how to re-create the queries again, where would you suggest I could go to get instruction. When I try to find my previous queries the only way I can see them in in the "database tools" tab under database documenter. I cannot call them up they are just listed there. I would appreciate it if you could send me in the direction of some online training. https://1drv.ms/f/s!AoXAY-dVeOkwuB-xR4Jn5NIE2bIv The link should share the database with you.

  6. #6
    orange's Avatar
    orange is online now Moderator
    Windows 10 Access 2010 32bit
    Join Date
    Sep 2009
    Location
    Ottawa, Ontario, Canada; West Palm Beach FL
    Posts
    16,716
    I downloaded your database. There are 51 queries.
    I have made a small report showing the query names and the query SQL. The report is attached.

    Here is the routine that produced the report.
    You can adjust the file name to reflect your directory.
    You can insert the ListQueries subroutine into a new module in your database, and run it when/as necessary.

    Code:
    '---------------------------------------------------------------------------------------
    ' Procedure : ListQueries
    ' Author    : mellon
    ' Date      : 11-Aug-2016
    ' Purpose   : Routine to list all queries in this database. It will print the query name
    ' and the SQL of the query to a file. You can change the name of the file to reflect your
    ' own info.
    '---------------------------------------------------------------------------------------
    '
    Sub ListQueries()
        Dim qdf As DAO.QueryDef
        Dim icnt As Integer
        Dim sTitleOfReport As String
        Dim QList As String
    
        'This is the default location where queries will be written.
        ' eg C:\users\yourUserName\ListQueries11_Aug_2016_08_14_40.txt
    
    10    On Error GoTo ListQueries_Error
    
    20    QList = "C:\users\mellon\documents\ListQueries" & Format(Now, "DD_MMM_YYYY_HH_NN_SS") & ".txt"
    
        'This is the default name of the Query List Report
    30    sTitleOfReport = " List of Current Queries "
    40    Open QList For Output As #1
    50
    60    Print #1, " " & sTitleOfReport & "         Date:" & Now()
    70    Print #1, "   "
    80        Print #1, " " & "Associated file is " & QList
    90    Print #1, "   "
    100   For Each qdf In CurrentDb.QueryDefs
    110     If Not Left(qdf.Name, 1) = "~" Then
    120         Debug.Print qdf.Name & vbCrLf & vbTab & qdf.SQL
    130         Print #1, "QUERY NAME:  " & qdf.Name & vbCrLf & "---------------------------"
    140         Print #1, vbCrLf & vbCrLf & vbTab & qdf.SQL
    150         icnt = icnt + 1
    160     End If
    170   Next qdf
    180   Debug.Print "Total number of queries is " & icnt
    190   Print #1, "Total number of queries is " & icnt
    200   Close #1
    
    210   On Error GoTo 0
    220   Exit Sub
    
    ListQueries_Error:
    
    230   MsgBox "Error " & Err.Number & " in line " & Erl & " (" & Err.Description & ") in procedure ListQueries of Module Mellon_Jack"
    End Sub
    When you open your database, be sure to hold down the shift key in order to see your queries.

    For online training --search youtube videos for 599CD (Richard Rost) he has a multi-part intro series that starts here.
    There are several free youtube videos that should be useful.

    Good luck.
    Attached Files Attached Files

  7. #7
    Helen Roberts is offline Novice
    Windows 10 Access 2007
    Join Date
    Jul 2016
    Posts
    5
    Hi,
    Thank you so much for all your time. The good luck remark is most appropriate, I will go on to the Youtube videos you suggest and take a look round as I am a real amateur with databases. Cheers

  8. #8
    orange's Avatar
    orange is online now Moderator
    Windows 10 Access 2010 32bit
    Join Date
    Sep 2009
    Location
    Ottawa, Ontario, Canada; West Palm Beach FL
    Posts
    16,716
    For Database concepts:
    Watch videos 1,2 and 4 in this series from Dr. Daniel Soper that starts here


    Work through 1 or both of these tutorials from RogersAccessLibrary.
    You have to work through the process to gain the experience , but you will learn.
    Class Info

    Consolidated Widgets

    Any youtube videos on Normalization would also be useful.

  9. #9
    Micron is offline Virtually Inert Person
    Windows 7 32bit Access 2007
    Join Date
    Jun 2014
    Location
    Ontario, Canada
    Posts
    12,737
    Is this a situation wherein during the OS upgrade you moved to a new version of Access and you can't see them because of some database option setting? I downloaded the db also and everything is quite visible; the only difference maybe is that I'm using the same version of Windows and Access that I've had for some time. Maybe you could post an image of what you're seeing when you open your db.
    The more we hear silence, the more we begin to think about our value in this universe.
    Paraphrase of Professor Brian Cox.

  10. #10
    Helen Roberts is offline Novice
    Windows 10 Access 2007
    Join Date
    Jul 2016
    Posts
    5
    Cheers, Orange ....... that will keep me busy

Please reply to this thread with any new information or opinions.

Similar Threads

  1. Replies: 3
    Last Post: 10-15-2014, 10:09 AM
  2. Totals Disappearing
    By Lesky in forum Reports
    Replies: 3
    Last Post: 04-09-2014, 09:41 AM
  3. Disappearing Act
    By CementCarver in forum Forms
    Replies: 4
    Last Post: 09-04-2013, 03:08 PM
  4. disappearing gridlines
    By lugnutmonkey in forum Reports
    Replies: 2
    Last Post: 05-06-2013, 01:26 AM
  5. disappearing combo box value
    By j6sander in forum Forms
    Replies: 5
    Last Post: 09-11-2012, 10:22 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Other Forums: Microsoft Office Forums