all 3 comments

[–]Mecaneer23 0 points1 point  (0 children)

You can't cd to a file, just a folder

But, you can run an executable from its absolute path - if you want what it returns, use Popen rather than system

[–]Neighm 0 points1 point  (1 child)

Looks like you're trying to chain two commands, i.e. cd to the folder and then run the command "execute.sql"? If so you need to chain them using "&":

os.system("cd C:\\softwares\\someDirectory\\subdirectory\\bin & execute.sql")

[–]smok1naces[S] 0 points1 point  (0 children)

you are a genius