hi i am harsha and i want a linux shellscript for connecting a mysql database and queries to copy a blob file from database and i need to parse that file and replace with other file can u pls help me its urgent


It is kind of hard to tell you how to write the script without knowing anything about the database, the tables and the fields involved. As far as a script is concerned you can simply put mysql code in a file and then redirect the file into mysql from the command line and it will execute.

For example:

text file called mycode.sql contains

use mydatabase;
select * from table1 order by table1.order_date, table1.order_number;

I can call it from the command line with

mysql -u user -ppassword < mycode.sql