I'm familiar with using JDBC and parsing ResultSet etc.
I'd like to know if there's a way to retrieve a MySql query result as pure string, just as if I were running it from the command line, with all the "+----------+" and stuff, just like here, or anywhere on MySql official site.
I'd like to be able to get queries from the user, pass them to some MySql blackbox as if I were passing it to the command line, and print the result to the user.
All solutions on the internet uses JDBC and isn't what I'm looking for. Any ideas?