Hello,
I have a simple Access table called "Test," with two columns - Field1 and Field2. The data in the table looks like this.
Field1 Field2
1 2
2 2
2 2
2 1
2 1
I'm trying to return the percentage of times each data type exists in each column. (ie - In Field1, the number 1 exists 20% and the number 2 exists 80%)
I found this query and it works great returning one column at a time.
Select Field1, (Count(Field1)* 100 / (select Count(*) From Test)) as fieldA
FROM Test
Group By Field1;
How would I select both columns? I tried this but it doesn't work.
Select Field1, (Count(Field1)* 100 / (select Count() From Test)) as fieldA,
Field2, (Count(Field2) 100 / (select Count(*) From Test)) as fieldB
FROM Test
Group By Field1;
Sorry for posting such a simple question. I haven't done much with Access.
Thanks,
Anne