01-13-2015 10:14 AM
Hi, I've six blocks of code. What I want is As code first takes lot of time to run, I want to run first then six and run two to four concurrently and I want them by a single sas code.. what I was doing I am using %include statements but this is not solving problem. Could there be any way by which I can run it parallely? Please help
01-13-2015 10:57 AM
You cannot multi-thread a program yourself if that's what you are attempting to do. SAS programs run iteratively, code is read block by block and executed. You can change the order this happens in, as you have mentioned with moving %include statements, but not run then at the same time.
01-14-2015 04:19 AM
Well, there is the proc ds2 options as mentioned previously, but you need 9.4 for that. Otherwise it is tricky. You could theoretically use the system command X to run sas.exe with a file name.
TBH I don't see what you are trying to achieve. If your code takes a while to finish, then look at some optimization/break the data down. Is that code related to other steps, if so then it needs to be finished before other ones.
If you really are running a universe simulation and require full multi-core processing, then invest some time in learning .NET/C++/Java, and write some software to do multi-threading.
As for EG/Connect, I do not know.
01-13-2015 01:32 PM
if you have SAS/CONNECT product licensed, then you can use MP Connect to spawn several SAS jobs in Parallel from within a single SAS session.
Here are few links to review:
Note: the links apply to all SAS 9.x versions!
Hope this helps,
01-13-2015 01:43 PM
If you are running a browser-based version of SAS, aka SAS Studio or SAS University Edition, then running code in parallel is not possible. You can have multiple SAS sessions open, but then you would have to split your code so that it can run independently without each session being aware of the other.
SAS EG (Enterprise Guide) and Foundation SAS/SAS Connect provide parallel running capabilities.
01-14-2015 04:50 AM
As you are at analytics_U webbased you do not have any options for parallel work. It is limitited by that intentionally