Solved

pivot table with text values

Posted on 2015-01-20
8
100 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:SimonAdept
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 31

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
 

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
What Should I Do With This Threat Intelligence?

Are you wondering if you actually need threat intelligence? The answer is yes. We explain the basics for creating useful threat intelligence.

 
LVL 31

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

Why You Should Analyze Threat Actor TTPs

After years of analyzing threat actor behavior, it’s become clear that at any given time there are specific tactics, techniques, and procedures (TTPs) that are particularly prevalent. By analyzing and understanding these TTPs, you can dramatically enhance your security program.

Join & Write a Comment

Introduction This Article is a follow-up to my Mappit! Addin Article (http://www.experts-exchange.com/A_2613.html), it was inspired by an email posting I made to EUSPRIG (http://www.eusprig.org/index.htm), I will briefly cover: 1) An overvie…
How to quickly and accurately populate Word documents with Excel data, charts and images (including Automated Bookmark generation) David Miller (dlmille) Synopsis In this article you’ll learn how to use ExcelToWord! to copy data,charts, shapes …
This Micro Tutorial will demonstrate in Microsoft Excel how to add style and sexy appeal to horizontal bar charts.
This Micro Tutorial will demonstrate how to create pivot charts out of a data set. I also added a drop-down menu which allows to choose from different categories in the data set and the chart will automatically update.

747 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

Need Help in Real-Time?

Connect with top rated Experts

9 Experts available now in Live!

Get 1:1 Help Now