Skip to content

Instantly share code, notes, and snippets.

@ssedano
Created November 8, 2012 14:48
Show Gist options
  • Save ssedano/4039219 to your computer and use it in GitHub Desktop.
Save ssedano/4039219 to your computer and use it in GitHub Desktop.
Small bash function to allow queries straight on the prompt.
function m {
for PARAM in "$@"
do
PARAMS="${PARAMS} ${PARAM}"
done
mysql -u[user] -p[password] -e "${PARAMS}" kinton
PARAM=""
PARAMS=""
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment