Starting with root, I want execute a sql script with another
$USER. But I have to set the right
With this command I receive error
export: command not found
su - $USER -c "export ORACLE_HOME=$ORA_HOME;export PATH=$ORA_HOME/bin:$PATH;sqlplus / as sysdba"
My question is: starting executing a script in root, how can I export a environment variable for another user and execute a command using that environment variable?