![]() | |
#1
| |||
| |||
|
#2
| |||
| |||
|
|
select region, issue, decode(value,'y','yes','n','no','--unknown--'),count (value) val_count, from data group by region, issue, decode(value,'y','yes','n','no','--unknown--'),count(value) |
#3
| |||
| |||
|
|
Dizzler, I do not see a question but remove the count(value) from your group by. Cheers, Jahudi Dizzler wrote: select region, issue, decode(value,'y','yes','n','no','--unknown--'),count (value) val_count, from data group by region, issue, decode(value,'y','yes','n','no','--unknown--'),count(value) |
#4
| |||
| |||
|
|
The question I replied to is below.... hi, I have a following table data- city region issue value c1 north i1 y c1 north i2 y c2 north i1 n c2 north i2 y c3 south i1 y c3 south i2 n c4 east i1 n c4 east i2 n This table has value for each issue in every city. How can I create a report from this which looks like- region issue count(yes) north i1 2 north i2 1 south i1 1 south i2 0 east i1 0 east i2 0 Please help/ideas for sql query "Jasper Scholten" <jasc27054 (AT) yahoo (DOT) co.uk> wrote in message news:euCdnavcnIjVTwXfRVnyiQ (AT) casema (DOT) nl... Dizzler, I do not see a question but remove the count(value) from your group by. Cheers, Jahudi Dizzler wrote: select region, issue, decode(value,'y','yes','n','no','--unknown--'),count (value) val_count, from data group by region, issue, decode(value,'y','yes','n','no','--unknown--'),count(value) |
![]() |
| Thread Tools | |
| Display Modes | |
| |