|
I have a long string variable (62 chars) with embedded underscore characters. Sample data:
THTR105_THTR205______
ELEC101_ELEC101_ELEC151_____
IRW101_IRW101_IRW151_IRW201_IRW201___
I want to retain the underscore within the string but remove all trailing occurrences of the string. Here is what I wrote:
* remove trailing underscore.
string newvar (a62).
compute newvar = rtrim(oldvar, '_').
The syntax does not generate an error message. It just runs, but the new variable still has the trailing underscores. Any assistance would be appreciated.
Cheryl Scott
IR Data Manager
TMCC Integrate Implementation Team
Office of Institutional Research
Truckee Meadows Community College
clscott@tmcc.edu
(775)673-8239 (w)
[text/html]
|