SAS—your wish is my command

This post was kindly contributed by The SAS Training Post - go there to comment and to read the full post.

I love to teach SAS programming and in this blog, I hope to share best practices, tips, tricks and answer some frequently asked questions by our SAS users. I’m constantly learning more nuances of SAS and more programming languages like SQL. Why the interest in language? As you probably know, people in Europe and India speak many languages. It’s not unusual to hear of fluency in four, sometimes five, languages!

So, let me start this blog with a question for you, dear reader: do squiggles make a script? The answer is yes they do! Take a look at this photo of a road sign I encountered during a recent trip to Delhi in four unique languages. Sometimes language is script-based; sometimes not (like scriptless Tulu which is still hotly debated) meaning people often have to rely on the spoken word. This contrasts greatly with the SAS world, which has well-written help and documentation in case you ever get lost and need to get back on track.

But I digress from my focus. Most of my passion for language can be attributed to growing up in the rich cultural mixing bowl that is India. I like to think that listening to colorful and vibrant sounds and reading a variety of scripted languages helped me to adapt more easily to a rich programming language like SAS.

What does daily language have to do with SAS?

Well, most of us speak in order to make ourselves understood by another. The same can be said with SAS: you learn the programming language in order to communicate your needs effectively to the software. In some ways, this conversation is much like Aladdin and the genie. Have you heard the story? A poor Persian boy named Aladdin is trapped in a cave by an evil magician. There, he finds a dusty lamp which he polishes and polishes until it shines. Magically, a genie appears and utters those famous words: “Your wish is my command.”

I’m sure you know the rest! Aladdin was able to receive anything that he could imagine, that he could properly articulate to the genie. I often tell my students that SAS is exactly the same. SAS can read almost any type of data (I’ll expand on that topic in a future post). With powerful engines working in the background, SAS will do exactly what you tell it to do. This is unlike other programming languages such as SQL which you can tell what to do, but may be surprised by the result! Under the hood, the SQL processor has a mind all of its own that may not quite function in the same way as yours, but more on that later. If I were to boil down this observation to a single sentence, I would sum it up as:

You can tell SQL what to do but not how to do it.
In SAS, what you ask for is what you get (and how you get it ).

Continue reading “SAS—your wish is my command”

This post was kindly contributed by The SAS Training Post - go there to comment and to read the full post.