Mysql command not working in shell script in oozie workflow


#1

Hi @viswanath.raju, @itversity1

I am using one shell script for sqoop and where mysql command is there to fetch some value. The script (.sh) is running fine in terminal, but failing in oozie script

First line of command in script is

value=$(mysql -h ms.itversity.com --user=retail_user --password=itversity --database = retail_export -s --execute=“select IFNULL(max(last_value),0) from log_item_sqoop”; )

Clearly getting error

<file_name> line 3: mysql: command not found

Could you please help on this??.. Any normal sqoop command is shell script working fine in oozie


#2

@Sushmita_Mondal Please follow below link for sqoop shell script example.