Results 1 to 3 of 3
  1. #1
    islandboy is offline Advanced Beginner
    Windows Vista Access 2007
    Join Date
    Jun 2009
    Posts
    63

    total records after running query and problem with macro error 2950


    hi guys.


    i have to questions to ask about queries and macros

    i will like to know if its possible to run a parameter query when the results come it could also have a total of items find.

    ex. if searching for male or female..shows names and the total of males in company hope i am clear.

    another problem that i have is with a macro. I run 2 queries one to append a record by entering the pass number, 2nd to delete that record by entering the same pass number.

    when i run it warnings me about that query that i am about to run, if i press yes it will ask me about the pass number, in that pint if i press cancel then i get an error number 2950

    hope you can help me guys, thanks

  2. #2
    CGM3 is offline Advanced Beginner
    Windows XP Access 2003
    Join Date
    Sep 2009
    Location
    Atlanta, GA
    Posts
    49
    The Count option might help with your first problem. In the design view of the query, click the "Sigma" (Totals, it looks like a capital sigma) button on the Query Design Toolbar, which adds a row to the query design labelled Total. The default value for a column is Group By, but if you change it to Count you get a count of the number of times a given value occurs in the query.

    I just came across this myself, so you may need to fiddle with it to make it useful. The test I did was on one table, with one field appearing twice in the query, once with the Group By "total", the other with the Count. Running this gave a list of each value of the field in the query result and the number of times that value appeared.

    For instance, using LastName as the field, instead of, say, getting SMITH three times, I got SMITH once with the Count of 3.

  3. #3
    islandboy is offline Advanced Beginner
    Windows Vista Access 2007
    Join Date
    Jun 2009
    Posts
    63
    Quote Originally Posted by CGM3 View Post
    The Count option might help with your first problem. In the design view of the query, click the "Sigma" (Totals, it looks like a capital sigma) button on the Query Design Toolbar, which adds a row to the query design labelled Total. The default value for a column is Group By, but if you change it to Count you get a count of the number of times a given value occurs in the query.

    I just came across this myself, so you may need to fiddle with it to make it useful. The test I did was on one table, with one field appearing twice in the query, once with the Group By "total", the other with the Count. Running this gave a list of each value of the field in the query result and the number of times that value appeared.

    For instance, using LastName as the field, instead of, say, getting SMITH three times, I got SMITH once with the Count of 3.
    thanks mate i got something out of it, i used Gender then Count again Gender then Group by...now if possible i want to get the total for both.

    thanks mate for the help.

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

Similar Threads

  1. Creating a Daily Running Total Query
    By seraph in forum Queries
    Replies: 0
    Last Post: 08-15-2009, 12:11 AM
  2. Running a Delete (Records) Query on Close
    By NoiCe in forum Queries
    Replies: 1
    Last Post: 07-12-2009, 06:17 PM
  3. error in macro
    By nawaray in forum Access
    Replies: 0
    Last Post: 02-10-2009, 12:06 PM
  4. Total records printed
    By LesleyA in forum Queries
    Replies: 3
    Last Post: 08-04-2008, 03:53 AM
  5. not correct running total in group
    By cmk in forum Reports
    Replies: 1
    Last Post: 12-06-2006, 05:56 PM

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