Query Question

L

ldiaz

I have a question about this fuction

Table

Planner W-Date Qty User6
BAM-06 10/22 1 CONC
BAM-06 10/22 2 CONC
JAXM-06 10/22 2 CONC
JAXM-06 10/22 1 CONC
BAM-06 10/23 1 CONC
BAM-06 10/23 1 CONC
JAXM-06 10/23 2 CONC
JAXM-06 10/23 2 CONC
BAM-06 10/22 1 TOC
BAM-06 10/22 2 TOC
JAXM-06 10/22 2 TOC
JAXM-06 10/22 1 TOC
BAM-06 10/23 1 TOC
BAM-06 10/23 1 TOC
JAXM-06 10/23 2 TOC
JAXM-06 10/23 2 TOC
BAM-06 10/22 1 TACT
BAM-06 10/22 2 TACT
JAXM-06 10/22 2 TACT
JAXM-06 10/22 1 TACT
BAM-06 10/23 1 TACT
BAM-06 10/23 1 TACT
JAXM-06 10/23 2 TACT
JAXM-06 10/23 2 TACT

what I want is datas like this:
CONC CONC TACT CONC TOC CONC
W-Date BAM-06 JAXM-06 BAM-06 JAXM-06 BAM-06 JAXM-06
22-Oct 3 3 3 3 3 3
23-Oct 2 4 2 4 2 4

Grouped by Want Date

please help

Thanks in advance
 
B

Bob Quintal

I have a question about this fuction

Table

Planner W-Date Qty User6
BAM-06 10/22 1 CONC
BAM-06 10/22 2 CONC
JAXM-06 10/22 2 CONC
JAXM-06 10/22 1 CONC
BAM-06 10/23 1 CONC
BAM-06 10/23 1 CONC
JAXM-06 10/23 2 CONC
JAXM-06 10/23 2 CONC
BAM-06 10/22 1 TOC
BAM-06 10/22 2 TOC
JAXM-06 10/22 2 TOC
JAXM-06 10/22 1 TOC
BAM-06 10/23 1 TOC
BAM-06 10/23 1 TOC
JAXM-06 10/23 2 TOC
JAXM-06 10/23 2 TOC
BAM-06 10/22 1 TACT
BAM-06 10/22 2 TACT
JAXM-06 10/22 2 TACT
JAXM-06 10/22 1 TACT
BAM-06 10/23 1 TACT
BAM-06 10/23 1 TACT
JAXM-06 10/23 2 TACT
JAXM-06 10/23 2 TACT

what I want is datas like this:
CONC CONC TACT CONC TOC CONC
W-Date BAM-06 JAXM-06 BAM-06 JAXM-06 BAM-06
JAXM-06 22-Oct 3 3 3 3 3 3
23-Oct 2 4 2 4 2 4

Grouped by Want Date

please help

Thanks in advance
Create the following Query..
SELECT W-Date, User6 & " "& Planner as HH, sum(Qty) as V FROM table
GROUP BY W-Date, User6 & " "& Planner;

Now change the query to a Crosstab Query
put Row Heading, Column Heading, Value in the crosstab: row of the
query.
 
L

ldiaz

Hi BOB, is not excactly what I was looking for, but it works, thank you so
much for your help

LD
 
B

Bob Quintal

Hi BOB, is not excactly what I was looking for, but it works,
thank you so much for your help

LD

If what you wanted was the column header on two lines, instead of a
single line, it is impossible.

If I misunderstood, please explain how it differs from what you wanted.
 
K

KARL DEWEY

How's about this ---
TRANSFORM Sum(IDVolatilDBID_lbl.QTY) AS SumOfQTY
SELECT IDVolatilDBID_lbl.[W-Date], Sum(IDVolatilDBID_lbl.QTY) AS [Total Of
QTY]
FROM IDVolatilDBID_lbl
GROUP BY IDVolatilDBID_lbl.[W-Date]
PIVOT [User6] & " - " & [Planner];
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top