Results 1 to 2 of 2
  1. #1
    marcusalie is offline Novice
    Windows 7 32bit Access 2003
    Join Date
    Apr 2011
    Posts
    2

    Need Help in ACCESS Query

    Posted - 04/01/2011 : 00:31:17 Hi all

    I have a FIXEDASSET table with quite a number of columns in particular 'PC_TYPE', 'DEPARTMENT'

    This table has about 50 over records with PC_TYPE column filled with "desktop" and "laptop"

    how to i do a query for counting number of laptop and desktop for respective departments

    Department | Laptop | Desktop
    Mgmt 2 3


    IT 3 5

    my code:
    SELECT (count(PC_TYPE) as" Number of Desktop" FROM FixedAsset where PC_TYPE='desktop ') , select (count(PC_TYPE) as "Number of laptop",PC_USER_DEPARTMENT from fixedasset where PC_Type='laptop')
    group by PC_USER_DEPARTMENT;

  2. #2
    pbaldy's Avatar
    pbaldy is offline Who is John Galt?
    Windows XP Access 2007
    Join Date
    Feb 2010
    Location
    Nevada, USA
    Posts
    22,521
    To get that look, play with the crosstab query wizard. You can add a criteria to restrict the result to those 2 types.
    Paul (wino moderator)
    MS Access MVP 2007-2019
    www.BaldyWeb.com

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

Similar Threads

  1. Replies: 10
    Last Post: 02-02-2011, 05:48 PM
  2. New to access and need help with query
    By zero3ree in forum Access
    Replies: 1
    Last Post: 02-12-2010, 05:03 AM
  3. Access Query
    By malaysarkar in forum Queries
    Replies: 0
    Last Post: 11-26-2009, 12:57 PM
  4. Sql server query to MS access query
    By blazixinfo@yahoo.com in forum Queries
    Replies: 0
    Last Post: 07-07-2009, 08:12 AM
  5. Access Query
    By LinneaUD13 in forum Queries
    Replies: 0
    Last Post: 06-05-2009, 03:46 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