216 |
if [[ -n ${primary} ]] |
if [[ -n ${primary} ]] |
217 |
then |
then |
218 |
# only run this if the primary key is not already the same column |
# only run this if the primary key is not already the same column |
219 |
i=( $(mysqldo 'SHOW COLUMNS FROM ${MCORE_SQL_DB}.${table} WHERE `Key`="PRI"') ) |
i=( $(mysqldo 'SHOW COLUMNS FROM '${MCORE_SQL_DB}.${table}' WHERE `Key`="PRI"') ) |
220 |
current_primary="${i[0]}" |
current_primary="${i[0]}" |
221 |
if [[ ${current_primary} != ${primary} ]] |
if [[ ${current_primary} != ${primary} ]] |
222 |
then |
then |