BookmarkSubscribeRSS Feed
pcfriendly
Calcite | Level 5


Hi All

I've got a table of data something like the below;

Month       Tech      Count

Jul-11          t1         234

Jul-11          t2         548

I'd like to have it create a new column & transpose to the below;

Month       Tech1   Tech2  Count

Jul-11         234      548      782

& therefore take up only one row instead of 2.

Normally, if I was using Excel, I would use a Pivot table to create extra columns & count the number of values.

I can't seem to get the 'Transpose' task in EG 4.3 to do this without adding extra columns instead of doing a 'Pivot' type of table.

I've found that I can use the 'Summary Tables Wizard' to get exactly the format I need but it is a report where I want to use this as a table for futher work.

I've seached everywhere for help on this but I need to know how to use this feature OR another if it does a better job using the Tasks available in EG & not have to write the code out.

Thanks in advance!!

2 REPLIES 2
andreas_lds
Jade | Level 19

In the fifth step of the wizard you should be asked whether the results should be stored in an dataset or not.

pcfriendly
Calcite | Level 5

Thanks andreas_Ids,

I assume you mean I should use the  'Summary Tables Wizard' to do this & select the 'Save results to a dataset' checkbox.

I've given this a try, but I'm finding that the Summary table comes out fine but the dataset itself doesn't come out in the same format.

Details that should be in the 'Columns' area are still in the 'Rows' area.

I've tried different settings fields etc & also the 'Transpose' function but I cannot get the data to come out as a table - the same way as the report...

Any further suggests?

sas-innovate-2024.png

Don't miss out on SAS Innovate - Register now for the FREE Livestream!

Can't make it to Vegas? No problem! Watch our general sessions LIVE or on-demand starting April 17th. Hear from SAS execs, best-selling author Adam Grant, Hot Ones host Sean Evans, top tech journalist Kara Swisher, AI expert Cassie Kozyrkov, and the mind-blowing dance crew iLuminate! Plus, get access to over 20 breakout sessions.

 

Register now!

SAS Enterprise Guide vs. SAS Studio

What’s the difference between SAS Enterprise Guide and SAS Studio? How are they similar? Just ask SAS’ Danny Modlin.

Find more tutorials on the SAS Users YouTube channel.

Click image to register for webinarClick image to register for webinar

Classroom Training Available!

Select SAS Training centers are offering in-person courses. View upcoming courses for:

View all other training opportunities.

Discussion stats
  • 2 replies
  • 3085 views
  • 3 likes
  • 2 in conversation