Results 1 to 6 of 6
  1. #1
    cap.zadi is offline Competent Performer
    Windows 7 32bit Access 2007
    Join Date
    May 2011
    Location
    KSA
    Posts
    481

    Rows into Column in a Report!

    Hey there,



    I would like to ask a question to create a report when having the following data tables which are updated through a one main form and 2 sub forms.
    table1
    TrnNo pk-AN
    TrnDate
    Product
    Machine

    table2

    RNO PK-AN
    TrnNO FK
    PrdDate
    GoodQty
    RejectQty


    table3

    RRNO PK-AN
    RNO FK
    CarNo
    RRejectQty
    Reason

    * table3 is used to describe the reject details of Table2 like if

    RejectQty = 10

    so in table3 it will be

    RRejectQty = 5
    Reason = Crack

    RRejectQty = 5
    Reason = Bend


    Now i am looking for a report where i can see the following sum by Prddate:

    Prddate
    product goodqty rejectqty Bend Crack
    AA 10 10 5 5

    How we can convert those reasons as column headings?


    thanks

    zee

  2. #2
    cap.zadi is offline Competent Performer
    Windows 7 32bit Access 2007
    Join Date
    May 2011
    Location
    KSA
    Posts
    481
    the file screen shots attached.

    if we see the query results so it double count the other rows because of reject reasons.

    how we can convert those reasons as column heading and there qty can be in row addressing to the concern record.

  3. #3
    June7's Avatar
    June7 is offline VIP
    Windows XP Access 2010 32bit
    Join Date
    May 2011
    Location
    The Great Land
    Posts
    53,624
    Did you try a Crosstab query?
    How to attach file: http://www.accessforums.net/showthread.php?t=70301 To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.

  4. #4
    cap.zadi is offline Competent Performer
    Windows 7 32bit Access 2007
    Join Date
    May 2011
    Location
    KSA
    Posts
    481
    yes but the sum is not correct for goodqty and rejectqty. plz advise bcz its very urgent to do.

  5. #5
    June7's Avatar
    June7 is offline VIP
    Windows XP Access 2010 32bit
    Join Date
    May 2011
    Location
    The Great Land
    Posts
    53,624
    Why wasn't it correct? Show the SQL statement you tried, show what the sample output should look like, provide full dataset for testing (Excel or Access file).
    How to attach file: http://www.accessforums.net/showthread.php?t=70301 To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.

  6. #6
    cap.zadi is offline Competent Performer
    Windows 7 32bit Access 2007
    Join Date
    May 2011
    Location
    KSA
    Posts
    481
    Hello Sir, how are you.

    here is the attached sample database and i think now all the questions merge into this thread.

    can you look at this thread and i am sure you can add some of your expertise.


    https://www.accessforums.net/queries...ata-21056.html

    thanks

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

Similar Threads

  1. Divide a column by another Column in a Report?
    By taimysho0 in forum Reports
    Replies: 2
    Last Post: 01-06-2012, 06:25 PM
  2. moving column data to rows
    By teasdam in forum Access
    Replies: 3
    Last Post: 12-23-2011, 08:39 AM
  3. Replies: 5
    Last Post: 12-01-2011, 05:38 PM
  4. split column into rows.
    By rsampathy in forum Access
    Replies: 1
    Last Post: 03-03-2011, 12:15 PM
  5. Sum of X's in column not rows, possible?
    By CoachBarker in forum Queries
    Replies: 7
    Last Post: 02-09-2011, 12:37 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