Solved

pivot table with text values

Posted on 2015-01-20
8
108 Views
Last Modified: 2015-01-22
I need to create a pivot table to summarize data, some of which is text.
The text values return as zeroes - is there a way to display them as text?
There is only one value for the row/column combination
0
Comment
Question by:szy8xj
8 Comments
 
LVL 18

Expert Comment

by:Simon
ID: 40560606
Only if you put the text fields as row or column items, not into the data area.
0
 

Author Comment

by:szy8xj
ID: 40560610
Boo! Thanks anyway!
0
 
LVL 32

Expert Comment

by:Rob Henson
ID: 40562063
You can replicate the Pivot Table function with Dbase formulas if you need to extract one set of data for a particular set of criteria, ie one result at a time rather than a table of results like a pivot.

All of the Dbase formulae have the following syntax:  =Dbase(Datatable,Field,Criteria)

DataTable - The datasource, same as you would use for the pivot
Field - The column header of the column from which you want the result
Criteria - A subset datatable with some or all of the same headers as source data and criteria specified under each.

The criteria table takes a bit of getting used to but is quite useful once you understand it.

Examples of DBASE functions are:
DSUM - add up a certain column (Field) based on criteria (similar to SUMPRODUCT or SUMIFS)
DMIN - return the minimum value from the specified column (Field) based on criteria
DMAX - return the maximum value from the specified column (Field) based on criteria
DGET - retrieve a single value from specified column (Field) that matches criteria, this can include text values.

Hope that helps.

Thanks,
Rob H
0
ScreenConnect 6.0 Free Trial

Discover new time-saving features in one game-changing release, ScreenConnect 6.0, based on partner feedback. New features include a redesigned UI, app configurations and chat acknowledgement to improve customer engagement!

 

Author Comment

by:szy8xj
ID: 40562148
So Bob, here is what I have in a nutshell....

Excel file -

Record looks like this: SSN, DATA ELEMENT NAME, VALUE
Number of SSN's is variable, number of DATA ELEMENTS per SSN is variable and not all SSN have the same DATA ELEMENTS, and VALUES depend on DATA ELEMENT NAME and are text and numeric.

I need to change this to one row per SSN with data element names as column headings and values under those headings in order to copy it into a template file - MS Access form.

I thought a pivot table with SSN as row identifier, Data Element name as Column heading and value. The numerics work great using MAX as the field setting but the text values come back as zero.

Will the DBASE technique get me that?

Thanks!
0
 
LVL 32

Expert Comment

by:Rob Henson
ID: 40562227
Can you upload a sample?

Thanks
Rob
0
 

Author Comment

by:szy8xj
ID: 40562515
Here is a sample file - the actual file has several thousand rows and up to 25 data elements - Thanks!
TESTFILE.xlsx
0
 
LVL 16

Accepted Solution

by:
Jerry Paladino earned 500 total points
ID: 40563970
If you Load or Link your Excel data as a table in Microsoft Access called "Tbl_Temp", the following SQL Query will transform your data into the format you are requesting...
TRANSFORM Max(Tbl_Temp.VALUE) AS MaxOfVALUE
SELECT Tbl_Temp.SSN
FROM Tbl_Temp
GROUP BY Tbl_Temp.SSN
PIVOT Tbl_Temp.[DATA ELEMENT];

Open in new window

Query Output
0
 

Author Closing Comment

by:szy8xj
ID: 40564062
Many thanks! This will be a big timesaver!
0

Featured Post

Optimizing Cloud Backup for Low Bandwidth

With cloud storage prices going down a growing number of SMBs start to use it for backup storage. Unfortunately, business data volume rarely fits the average Internet speed. This article provides an overview of main Internet speed challenges and reveals backup best practices.

Question has a verified solution.

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

Introduction This Article briefly covers methods of calculating the NPV and IRR variants in Excel as well as the limitations in calculating and interpreting IRR results. Paraphrasing Richard Shockley, author of my favourite finance reference tex…
This code takes an Excel list of URL’s and adds a header titled “URL List”. It then searches through all URL’s in column “A”, looking for duplicates. When a duplicate is found, it is moved to the top of the list. The duplicate URL’s are then highlig…
This Micro Tutorial demonstrates how to create Excel charts: column, area, line, bar, and scatter charts. Formatting tips are provided as well.
This Micro Tutorial will demonstrate how to use a scrolling table in Microsoft Excel using the INDEX function.

809 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