?
Solved

access crosstab query for subreport with multiple rows

Posted on 2015-02-16
2
Medium Priority
?
82 Views
Last Modified: 2015-03-11
I am needing to get a result from a joined table  for a subreport
I need
RequestID|Qty|ItemNumber|InvoicePrice|correctPrice

here is sample of a dataset with same requestID there can be are mutilple requestID for data
RequestValueID      RequestID      FieldDescription      CreditReasonFieldID      RequestValue      SortOrder
470479      82307      Quantity      3      1      1
470480      82307      Quantity      3      1      1
470481      82307      Quantity      3      3      1
470482      82307      Quantity      3      1      1
470483      82307      Quantity      3      1      1
470484      82307      Quantity      3      2      1
470485      82307      Quantity      3      1      1
470486      82307      Quantity      3      1      1
470487      82307      Quantity      3      7      1
470488      82307      Quantity      3      1      1
470489      82307      Quantity      3      1      1
470490      82307      Quantity      3      2      1
470491      82307      Quantity      3      5      1
470492      82307      Quantity      3      1      1
470493      82307      Quantity      3      1      1
470504      82307      Item Number      4      85006      2
470505      82307      Item Number      4      85863      2
470506      82307      Item Number      4      86212      2
470507      82307      Item Number      4      86213      2
470508      82307      Item Number      4      86230      2
470509      82307      Item Number      4      86445      2
470510      82307      Item Number      4      86448      2
470511      82307      Item Number      4      125032      2
470512      82307      Item Number      4      125039      2
470513      82307      Item Number      4      126035      2
470514      82307      Item Number      4      126039      2
470515      82307      Item Number      4      4-010793-00      2
470516      82307      Item Number      4      4-048493-00      2
470517      82307      Item Number      4      5-18537      2
470518      82307      Item Number      4      5-18541      2
470519      82307      Invoiced Price      5      130.13      3
470520      82307      Invoiced Price      5      51.85      3
470521      82307      Invoiced Price      5      51.05      3
470522      82307      Invoiced Price      5      51.05      3
470523      82307      Invoiced Price      5      11.51      3
470524      82307      Invoiced Price      5      16.02      3
470525      82307      Invoiced Price      5      16.02      3
470526      82307      Invoiced Price      5      58.06      3
470527      82307      Invoiced Price      5      58.06      3
470528      82307      Invoiced Price      5      68.07      3
470529      82307      Invoiced Price      5      68.07      3
470530      82307      Invoiced Price      5      105.37      3
470531      82307      Invoiced Price      5      31.28      3
470532      82307      Invoiced Price      5      188.19      3
470533      82307      Invoiced Price      5      188.19      3
470534      82307      Correct Price      6      120.00      4
470535      82307      Correct Price      6      42.80      4
470536      82307      Correct Price      6      46.00      4
470537      82307      Correct Price      6      46.00      4
470538      82307      Correct Price      6      9.80      4
470539      82307      Correct Price      6      13.70      4
470540      82307      Correct Price      6      13.70      4
470541      82307      Correct Price      6      49.00      4
470542      82307      Correct Price      6      49.00      4
470543      82307      Correct Price      6      49.00      4
470544      82307      Correct Price      6      49.00      4
470545      82307      Correct Price      6      99.70      4
470546      82307      Correct Price      6      4.40      4
470547      82307      Correct Price      6      144.00      4
470548      82307      Correct Price      6      144.00      4
470549      82307      Quantity      3      1      1
470550      82307      Item Number      4      86446      2
470551      82307      Invoiced Price      5      16.02      3
470552      82307      Correct Price      6      13.70      4
0
Comment
Question by:KurtRoss
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 51

Accepted Solution

by:
Gustav Brock earned 2000 total points
ID: 40612949
?
You leave us guessing.

/gustav
0
 
LVL 10

Expert Comment

by:Gozreh
ID: 40613512
You can not create a crosstab with one RequestID, it can give you only one result for each RequestID.

TRANSFORM First(Table1.RequestValue) AS FirstOfRequestValue
SELECT Table1.RequestID
FROM Table1
GROUP BY Table1.RequestID
PIVOT Table1.FieldDescription;
0

Featured Post

Ransomware: The New Cyber Threat & How to Stop It

This infographic explains ransomware, type of malware that blocks access to your files or your systems and holds them hostage until a ransom is paid. It also examines the different types of ransomware and explains what you can do to thwart this sinister online threat.  

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

The Windows Phone Theme Colours is a tight, powerful, and well balanced palette. This tiny Access application makes it a snap to select and pick a value. And it doubles as an intro to implementing WithEvents, one of Access' hidden gems.
If you need a simple but flexible process for maintaining an audit trail of who created, edited, or deleted data from a table, or multiple tables, and you can do all of your work from within a form, this simple Audit Log will work for you.
In Microsoft Access, learn how to use Dlookup and other domain aggregate functions and one method of specifying a string value within a string. Specify the first argument, which is the expression to be returned: Specify the second argument, which …
In Microsoft Access, when working with VBA, learn some techniques for writing readable and easily maintained code.

719 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question