BookmarkSubscribeRSS Feed
Calcite | Level 5
Hi all, Two questions:

#1 - autosort with decimals and/or percent signs
I was just wondering if anyone had any thoughts on sorting numbers with decimals. I actually have numbers I format as percent8.2 and output with proc report (column is set for display). The sort='yes' function of the tagset works, but it sorts it as text. I thought perhaps it was because of the percent sign so I tried just outputting the number*100 to avoid the percent sign but it still sorts like text. Perhaps it is the decimal? Unfortunately I need to present whole numbers to two decimal points, but I could live without percent signs. Anyone have any clever workaround ieas? Example of how my data is sorting (descening obviously):
[pre] 25.72
#2 autofilter columns - limiting to just 3 columns
Same table as above (proc report in ods tagsets.tableeditor). If I use just sort='yes' then sort works. If I use sort='yes and auto_filter='yes' then I can sort and all columns have (populated) filter boxes. What I really want is filter boxes on just 3 columns. Below is the code I use, but when I add filter_cols='1,2,3' sort doesn't work and no filter boxes show up. Saw this in both IE7 and IE8.
ods tagsets.tableeditor style=analysis
path="c:\temp\" body="test.htm"(title="test level")
options(highlight_color='#fff8cd' sort='yes' autofilter='yes' filter_cols='1,2,3');
One more strange twist is that if I say filter_cols='2,3' then all the columns have filter boxes, but only col2 and col3 have values in them.
Calcite | Level 5
Re #2
I just tried the autofilter_endcol option and that seemed to work since what I am trying to do is just the first 2 or 3 columns...
ods tagsets.tableeditor style=analysis
path="c:\temp\" body="test.htm"(title="test level")
options(highlight_color='#fff8cd' sort='yes' autofilter='yes' autofilter_endcol='2');
Still looking for help on #1.
I'm not that familiar with tagsets.tableeditor and how it works. You might look to Tech Support for help with #1. If they don't know the answer, they can find the person who wrote the tagset and ask for help.

Calcite | Level 5
I believe I ran into this problem previously and used the following tableeditor tagset option to force the proper data type.

I don't have time to test but as I recall, this solved a similar problem that I had.



Available on demand!

Missed SAS Innovate Las Vegas? Watch all the action for free! View the keynotes, general sessions and 22 breakouts on demand.


Register now!

How to Concatenate Values

Learn how use the CAT functions in SAS to join values from multiple variables into a single value.

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
  • 3 replies
  • 3 in conversation