BookmarkSubscribeRSS Feed
Sajid01
Meteorite | Level 14

Thank you @SASKiwi and @Patrick for enlightening about this fact.

It would be good if SAS can do something about it

tom_grant
SAS Super FREQ

tom_grant_0-1670351532702.png

FYI You can set options (like validvarname) using the More Application Option button & selecting preferences & saving.

SASKiwi
PROC Star

@tom_grant  - Yes, I'd seen that thanks. My point being that you can't enforce it as a SAS installation or application default even though you can do it for programs not run in SAS Studio. It causes inconsistencies when running the same applications in say both SAS Studio and batch mode for example.

 

EDIT: I have a SAS application that sets VALIDVARNAME = V7 in a control or master program that sets up the application environment. It works as intended in Enterprise Guide or batch across all users regardless of how many program submits you do. It won't work in SAS Studio unless I get all users to individually configure their SAS Studio options. There should be a way to turn off compulsory submission options globally rather than just override them.

Quentin
Super User

In the similar menu in EG, there  you can choose to set validvarname  to V7/Any/etc or you cat set it to "use setting from server".  Is there a "use setting from server" choice for Studio?

 

The bigger annoyance for me as a developer (not an admin), as I understand in Studio if  I submit an options statement to change the value of VALIDVARNAME, and then submit another block of code, the value of VALIDVARNAME will be reset for the second submission.  That seems like it would be really annoying.

BASUG is hosting free webinars Next up: Mark Keintz presenting History Carried Forward, Future Carried Back: Mixing Time Series of Differing Frequencies on May 8. Register now at the Boston Area SAS Users Group event page: https://www.basug.org/events.
SASKiwi
PROC Star

@Quentin - EG also sets VALIDVARNAME = EXTEND by default, but honours any previous setting of this option either in an AUTOEXEC or any other SAS program. This is also how the SAS Windowing System and SAS batch jobs work. This is how SAS Studio should behave, but it doesn't and going around configuring all SAS Studio user sessions individually doesn't sound like a good fix to me.

 

You are absolutely correct in your observations, but to me the biggest problem is SAS Studio doesn't behave the same as other types of SAS sessions. I build SAS applications so they run the same in any environment: SAS Studio, EG, batch mode. At the moment I can't guarantee that my SAS applications will run correctly in all SAS Studio sessions as they all set the VALIDVARNAME = V7 option at the start of each one.

 

I simply don't see the reason to reset SAS options for every program submission. There should be a installation default setting to turn this SAS Studio feature off. 

kshangaun
Calcite | Level 5

Hi all,

I'm trying to learn SAS using books and online resources. I prefer to learn stuff doing something more than just reading or watching videos about them.

So I go on Stackoverflow and I try to see if I can answer any question about the thing I'm learning. Of course at the beginning often I'm not even able to understand the questions, but after a while I can see a light at the end of the tunnel. Anyway I try to do a lot of google-fu to figure out a solution and I feel it's good to learn even if I get no points on SO.

Reading books and watching the videos I saw a lot of SAS commands, but on internet a lot of problems are solved using PROC SQL.

Now my doubt is: I know SQL pretty well, how much effort should I put in learning SAS commands? Is it better to use PROC SQL and what I already know or using SAS language is better? and why?

Kurt_Bremser
Super User

Only using SQL in SAS would deprive you of the other 99+ percent of what the SAS system provides. And you would be stuck with something which is (by nature) much less performant than these other 99+ percent.

 

Please post your questions in a topic of your own. Old threads provide much less exposure to your questions, especially when the topic has nothing in common with your question.

Shmuel
Garnet | Level 18

You asked "how much effort should I put in learning SAS commands? Is it better to use PROC SQL and what I already know or using SAS language is better?"

 

SAS SQL is a little different then other systems' SQL. You can use SAS functions and some SAS file options within SAS SQL. 
SAS Base, in some cases, is shorter in code and more efficient. Sas Base contains statements (commands), functions and many procedures. 
Some of these code may differ depending on the SAS platform you use.

You should look for a learning program in order to progress efficiently to get a good experience. 

sas-innovate-2024.png

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!

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
  • 22 replies
  • 2031 views
  • 11 likes
  • 11 in conversation