Results 1 to 2 of 2
  1. #1
    Join Date
    Sep 2016

    Unanswered: New to ACCESS **need help

    Need Help

    I have Supplier names and then I also have count of parts we buy from these supplier. Which function or Criteria I should use to get Count of "Unique part numbers" from each supplier.

    I am trying to use DCount


    I am using Access 2010 .Query builder

  2. #2
    Join Date
    Jan 2009
    Kerala, India
    Create a Total Query with the following SQL with appropriate changes:

    SELECT [tblSpend2016].[Supplier ID], [tblSpend2016].[PART], Count([tblSpend2016].[PART]) AS PARTCNT
    FROM [tblSpend2016]
    GROUP BY [tblSpend2016].[Supplier ID], [tblSpend2016].[PART];
    and save the Query with the Name: QUERY1. After that you can use the following expression, as you were trying to get the required output:

    =DSUM("PARTCNT","QUERY1","[Suppler ID]=XYZ123")

    Insert the correct supplier ID in place of XYZ123. Insert the correct Supplier information in place of [Supplier ID] in the SQL and in the =DSUM() function as well.
    Last edited by apr pillai; 09-19-16 at 14:14. Reason: correction of text (Learn MS-Access Tips & Tricks)
    Learn Advanced MS-Access Programming with sample VBA Code.

    All responses are based on Access 2003/2007

Posting Permissions

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