Use Variable Inside String Javascript Substring Syntax In Mysql