I'm using MySql commandline 5.6.11 and when I try to see my stored procedure in the command line like
SHOW PROCEDURE CODE sp_my_procedure
I'm getting:
ERROR 1289 (HY000): The 'SHOW PROCEDURE|FUNCTION CODE' feature is disabled; you need MySQL built with '--with-debug' to have it working
How do I use the command to run mysql with "--with-debug" in Windows (I saw the documentation but it talks about how to do that in Linux)?
You need to compile your mysql binary by yourself, see http://dev.mysql.com/doc/refman/5.6/en/source-installation.html, because of
SHOW PROCEDURE CODE proc_name
This statement is a MySQL extension that is available only for servers
that have been built with debugging support.
But maybe SHOW CREATE PROCEDURE gives you what you want.
Related
I'm trying to add the employee sample database for practicing with MySQL however there's an error since there's a source command and from what I've found it says that MySQL doesn't support this command anymore.
So, how could I add the complete database without any error?
[this is the code line where the source command is called]
SOURCE is one of the mysql client builtin commands. These are recognized by the mysql client, but not by the MySQL Server's SQL parser.
See https://dev.mysql.com/doc/refman/8.0/en/mysql-commands.html
I'm trying to start with MySQL and stored procedures. I'm a visual studio user and I found https://dev.mysql.com/doc/visual-studio/en/visual-studio-install.html. I would like to use VS because of the debugging capabilities.
I installed both MySQL for Visual Studio and the connector. I can connect to the database, view the tables, view the stored procedures, ...
But when I double click a stored procedure I get an error: "Unable to load the stored procedure for editing". VS continues and shows a blank document. The same happens when I right click and select 'Alter routine'.
I don't know if it is important but I'm not using a MySQL installation but MySQL in XAMP (MariaDB).
How can I fix this issue?
You should modify connection on your Server Explorer
And then check on checkbox "Save my password"
I have some troubles to use Entity Framework 6 and MySQL. I use Visual Studio 2015 and Entity Framework6.
After I click finish button on this wizard window:
I get this error window:
Why do I get error above, and how can I fix it? I don't have a table named 'TableDetails'.
Entity Framework (version 6.1.3) and MySQL Server (5.7)
Open Services (services.msc) and restart MySQL57 service.
Execute the following commands in MySQL.
use <>;
set global optimizer_switch='derived_merge=OFF';
Update the .edmx.
I hope this will work for u.
Thanks CodeCaster I found solution in forum he referenced in comment above.
Use this command in MySQL command line client:
use <<database name>>;
set global optimizer_switch='derived_merge=off';
set optimizer_switch='derived_merge=off';
I am trying to install the metastore in mysql. When I looked at the source code, there are many sql scripts but they are all upgrades. Which /where is the start-from-scratch DDL for the metastore?
The cloudera docs have this info (for version 0.10.0):
mysql> CREATE DATABASE metastore;
mysql> USE metastore;
mysql> SOURCE /usr/lib/hive/scripts/metastore/upgrade/mysql/hive-schema-0.10.0.mysql.sql;
But I do not see anything for version 11.0
So the answer is : The version 0.10.0 "upgrade" script (as shown in OP) is actually the correct one to invoke . Although the name is "upgrade" it is used to create the initial schema.
Is there an error in this code SHOW PROCEDURE CODE proc_name?
The MySQL documentation says it's correct, but I keep receiving a 1064 error anytime I run the code.
This statement is a MySQL extension that is available only for servers that have been built with debugging support.
So, obviously your mysql does not have debugging enabled
because error 1064 stand for parse error.
To enable debug in mysql, is quite straightforward :-
http://dev.mysql.com/doc/refman/5.0/en/server-options.html#option_mysqld_debug
provide mysql is configured --with-debug
You can get your informations from here:
SELECT ROUTINE_DEFINITION FROM information_schema.ROUTINES WHERE SPECIFIC_NAME='proc_name'