Home > database >  Mysql stored procedures using dbforge tracking debug, a lot more. CALL cr_debug UPDATE_WATCH, how ta
Mysql stored procedures using dbforge tracking debug, a lot more. CALL cr_debug UPDATE_WATCH, how ta

Time:09-21

The CREATE DEFINER=` rootdba ` @ % ` ` PROCEDURE ` case_30day_ser4 ` (OUT out_flag INT, out_table VARCHAR (200))
The BEGIN
DECLARE cr_stack_depth INTEGER DEFAULT cr_debug. ENTER_MODULE2 (' case_30day_ser4 ', 'parts', 7, 100632)/* */[cr_debug. 1];
DECLARE l_serial_number VARCHAR (50);
DECLARE l_Account_Name VARCHAR (200);
DECLARE l_open_date DATETIME.
DECLARE l_row_num_team VARCHAR (20);
DECLARE l_sub_gbu VARCHAR (30);
DECLARE l_num INT.
/* definition cursor */
DECLARE cu_case CURSOR FOR the SELECT DISTINCT ` serial_number `, ` Account_Name `, ` open_date `, ` row_num_team `, ` sub_gbu ` FROM temp_case_ser7 ORDER BY row_num_team, open_date;
DECLARE the CONTINUE HANDLER FOR the NOT FOUND the BEGIN/* [cr_debug. 3, 5] */
DECLARE cr_stack_depth INTEGER DEFAULT cr_debug. ENTER_HANDLER (' case_30day_ser4_Handler ', 'case_30day_ser4', 'parts', 7, 100632)/* */[cr_debug. 2];
CALL cr_debug. UPDATE_WATCH3 (l_serial_number 'l_serial_number', 'a VARCHAR (50)', cr_stack_depth)/* */[cr_debug. 2];
[color=# FF0000] CALL cr_debug. UPDATE_WATCH3 (' l_Account_Name l_Account_Name, 'a VARCHAR (200)', cr_stack_depth)/* */[cr_debug. 2];
CALL cr_debug. UPDATE_WATCH3 (' l_open_date l_open_date, 'a DATETIME, cr_stack_depth)/* */[cr_debug. 2];
CALL cr_debug. UPDATE_WATCH3 (' l_row_num_team l_row_num_team, 'VARCHAR (20)', cr_stack_depth)/* */[cr_debug. 2];
CALL cr_debug. UPDATE_WATCH3 (' l_sub_gbu l_sub_gbu, 'VARCHAR (30)', cr_stack_depth)/* */[cr_debug. 2];
[/color]

CodePudding user response:

Finish testing of the stored procedure, add a lot of debugging in other tools with statement information, so right-click the stored procedure again in debugging is completed, then the Debug, and select the Compile or direct press Ctrl + F7
This time you can see the database one more cr_debug library
To correspond of database users granted cr_debug libraries need to debug all permissions and mysql database select privilege, when this kind of treatment can be normal use after dbforge studio for mysql debugging capabilities
  • Related