Don't miss Joystiq's up-to-the-minute live coverage of E3!

TIPS: Getting CAT-ty With SAS

That Was Easy - StaplesHere's a good tip lifted from the e-pages of the July issue of Your SAS Technology Report.

Ever write code like the following to concatenate a bunch of fields and drive yourself crazy debugging the unbalanced parentheses, quotes, and concatenation bars resulting from the inevitable typo?

TRIM(LEFT(X1)) || ' ' || TRIM(LEFT(X2)) || ' ' || TRIM(LEFT(X3)) || ' ' || TRIM(LEFT(X4))

Well then, do your eyes a big favor and learn about the new CATX function of SAS 9, which accomplishes the same thing with this terse code:

CATX(' ', OF X1-X4)

That Was Easy!

RESOURCES

RSS NEWSFEEDS

Powered by Blogsmith

Other Weblogs Inc. Network blogs you might be interested in: