load a file to mysql DB

i try to load a text file to mysql DB wit shell script but the handler MySQLLOadFile() does not work, i am dommi in shell script, can any body help me?

property mysql : load script (file "vike:Library:ASXtras:mySQL4AppleScript:mysql")

(*tell mysql to CreateLogInString("root", "", "localhost")
tell mysql to SetTheDataBase("ecsa")
tell mysql to ShowDataBases()*)

property mySQLarchivo : (choose file) as string
property mySQLFile : POSIX path of mySQLarchivo

property usuario : mysql's SetCurrentUser("root")

property pass : mysql's SetCurrentPassword("")
property DB : mysql's SetTheDataBase("ecsa")
property GetDB : mysql's GetTheDataBase()
property CPLOgSTR : mysql's CreateLogInString(usuario, pass, "localhost")
property CPdataBaseString : " -D " & "'" & DB & "'"
property CPmySQLCommand : "/usr/local/mysql/bin/mysql"


MySQLLOadFile()

on conecta()
	
	set CPmySQLDescribe to " -e \"" & "DESCRIBE " & "\\`pantones\\`" & "\""
	
	set CPmySQLCommand to CPmySQLCommand & CPLOgSTR & CPdataBaseString & CPmySQLDescribe
	
	--do shell script CPmySQLCommand
	
end conecta


on MySQLLOadFile()
	
	set CPLoadLocal to " -e \"" & "LOAD DATA LOCAL INFILE " & "\\`" & mySQLFile & "\\`" & " INTO TABLE" & "\\`" & "colores" & "\\`" & " " & "\""
	
	set CPmySQLCommand to CPmySQLCommand & CPLOgSTR & CPdataBaseString & CPLoadLocal
	
	do shell script CPmySQLCommand
	
	
end MySQLLOadFile

I was thinking about writing a script something like this myself (but I was going to do it as a droplet). In case it helps, I found out while using this command interactively at the MySQL command line, that I had to enclose the file path in double quotes despite the fact that someone who posted on the MySQL site indicated single quotes for this use. Maybe it depends on just what kind of characters are in the path which you’re working with at the time.

I found a short and easy answer to my trouble

set mySQLCommand_LoadFile to do shell script "/usr/local/mysql/bin/mysql -D " & mysql_db & " -u " & mysql_user & " -h " & mysql_host & " -p" & mysql_pw & " -e  'LOAD DATA LOCAL INFILE \"path/file.txt\" into table"