BookmarkSubscribeRSS Feed
☑ This topic is solved. Need further help from the community? Please sign in and ask a new question.
ssafmed
Obsidian | Level 7

I have 2 ksh (korn shell script) : file1.ksh and file2.ksh; and I want to have a master file ksh script that will call the 2 files; what's the code I have to put in my master file?

 

Thanks 

1 ACCEPTED SOLUTION

Accepted Solutions
gwootton
SAS Super FREQ
This isn't really a SAS question but a question about how to use korn shell so this may not be the best place to ask, but if you wanted to run one script from another wouldn't you just put the path to that script in your "master" script?
#!/bin/ksh
/path/to/file1.ksh

If you wanted to source the file rather than run it you could use the "source" command or it's alias, ".":
. /path/to/file1.ksh
or
source /path/to/file1.ksh
--
Greg Wootton | Principal Systems Technical Support Engineer

View solution in original post

4 REPLIES 4
data_null__
Jade | Level 19

.  file [arguments]

 

It is called the DOT command.  

ssafmed
Obsidian | Level 7

I dont see your answer

ssafmed
Obsidian | Level 7

I need please a sample code that will be in the master file

I m new in shell

 

thanks

gwootton
SAS Super FREQ
This isn't really a SAS question but a question about how to use korn shell so this may not be the best place to ask, but if you wanted to run one script from another wouldn't you just put the path to that script in your "master" script?
#!/bin/ksh
/path/to/file1.ksh

If you wanted to source the file rather than run it you could use the "source" command or it's alias, ".":
. /path/to/file1.ksh
or
source /path/to/file1.ksh
--
Greg Wootton | Principal Systems Technical Support Engineer

suga badge.PNGThe SAS Users Group for Administrators (SUGA) is open to all SAS administrators and architects who install, update, manage or maintain a SAS deployment. 

Join SUGA 

Get Started with SAS Information Catalog in SAS Viya

SAS technical trainer Erin Winters shows you how to explore assets, create new data discovery agents, schedule data discovery agents, and much more.

Find more tutorials on the SAS Users YouTube channel.

Discussion stats
  • 4 replies
  • 1163 views
  • 0 likes
  • 3 in conversation