update_transcript_i.sh 534 B

12345678910111213141516171819
  1. #!/bin/bash
  2. #update_transcripts,sh
  3. #USAGE sh update.sh transcript_potri
  4. display_usage() {
  5. echo "\nUsage:\n$0 [table_name] \n"
  6. }
  7. # if less than one arguments supplied, display usage
  8. if [ $# -le 0 ]
  9. then
  10. display_usage
  11. exit 1
  12. fi
  13. /usr/bin/mysql --defaults-file="$(dirname "$0")"/.mysql.cnf --local_infile=1 <<EOFMYSQL
  14. UPDATE $1 INNER JOIN transcript_info on transcript_info.transcript_id = $1.transcript_id SET $1.transcript_i = transcript_info.transcript_i;
  15. EOFMYSQL