[Koha-bugs] [Bug 10517] koha-restore fails to create mysqluser at mysql_hostname so zebra update fails

bugzilla-daemon at bugs.koha-community.org bugzilla-daemon at bugs.koha-community.org
Thu May 7 08:59:21 CEST 2020


https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=10517

--- Comment #25 from Rudolf Byker <rudolfbyker at gmail.com> ---
OK, if you really need to support older versions, let's do it cleanly. Here is
a way to check if the user exists:

EXISTS=$(mysql -uroot -p -s -e "select count(*) from mysql.user where user =
'asdf'" | tail -n 1)
if [[ $EXISTS -gt 0 ]]
then
  echo "Now delete the user."
fi

-- 
You are receiving this mail because:
You are watching all bug changes.


More information about the Koha-bugs mailing list