157 |
where_statement="$2" |
where_statement="$2" |
158 |
fi |
fi |
159 |
|
|
160 |
export eval $(mysql \ |
eval $(mysql \ |
161 |
--user="${SQL_USER}" \ |
--user="${SQL_USER}" \ |
162 |
--password="${SQL_PASS}" \ |
--password="${SQL_PASS}" \ |
163 |
--host="${SQL_HOST}" \ |
--host="${SQL_HOST}" \ |
165 |
--xml \ |
--xml \ |
166 |
--execute="select * from ${table} ${where_statement}" \ |
--execute="select * from ${table} ${where_statement}" \ |
167 |
| xml sel -T -t -m //row/field \ |
| xml sel -T -t -m //row/field \ |
168 |
-v "concat('${table}_', @name, '=', '\"' ,self::field, '\"')" -n) |
-v "concat('${table}_', @name, '=', '\"', self::field, '\"')" -n) |
169 |
} |
} |
170 |
|
|
171 |
# runs a statement and evaluate the resulting columns |
# runs a statement and evaluate the resulting columns |
184 |
prefix="${prefix}_" |
prefix="${prefix}_" |
185 |
fi |
fi |
186 |
|
|
187 |
export eval $(mysql \ |
eval $(mysql \ |
188 |
--user="${SQL_USER}" \ |
--user="${SQL_USER}" \ |
189 |
--password="${SQL_PASS}" \ |
--password="${SQL_PASS}" \ |
190 |
--host="${SQL_HOST}" \ |
--host="${SQL_HOST}" \ |