Server IP : 172.67.216.182 / Your IP : 172.68.164.90 Web Server : Apache System : Linux krdc-ubuntu-s-2vcpu-4gb-amd-blr1-01.localdomain 5.15.0-142-generic #152-Ubuntu SMP Mon May 19 10:54:31 UTC 2025 x86_64 User : www ( 1000) PHP Version : 7.4.33 Disable Function : passthru,exec,system,putenv,chroot,chgrp,chown,shell_exec,popen,proc_open,pcntl_exec,ini_alter,ini_restore,dl,openlog,syslog,readlink,symlink,popepassthru,pcntl_alarm,pcntl_fork,pcntl_waitpid,pcntl_wait,pcntl_wifexited,pcntl_wifstopped,pcntl_wifsignaled,pcntl_wifcontinued,pcntl_wexitstatus,pcntl_wtermsig,pcntl_wstopsig,pcntl_signal,pcntl_signal_dispatch,pcntl_get_last_error,pcntl_strerror,pcntl_sigprocmask,pcntl_sigwaitinfo,pcntl_sigtimedwait,pcntl_exec,pcntl_getpriority,pcntl_setpriority,imap_open,apache_setenv MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : OFF | Sudo : ON | Pkexec : ON Directory : /www/server/mysql/src/mysql-test/suite/ndb_ddl/ |
Upload File : |
if (!$create_table_name) { die Need the name of temporary table where to put list of objects; } if (!$list_table_name) { die Need the name of the table to list objects for; } --disable_query_log # Create temporary table for storing the original # list of objects in the table eval CREATE TEMPORARY TABLE $create_table_name ( id INT UNSIGNED PRIMARY KEY, type INT UNSIGNED, version INT UNSIGNED, state INT UNSIGNED, parent_obj_type INT UNSIGNED, parent_obj_id INT UNSIGNED, fq_name VARCHAR(512) ); # Split the table_name variable into db and name part # since ndbinfo.ndb$dict_obj_info.parent_fq_name uses format # db/catalog/name let $_db = `SELECT IF(INSTR('$list_table_name', '.'), SUBSTRING_INDEX('$list_table_name', '.', 1), 'ndb_ddl_test')`; # Default to ndb_ddl_test let $_name = `SELECT SUBSTRING_INDEX('$list_table_name', '.', -1)`; # Create a view on top of ndbinfo.ndb$dict_obj_info (as otherwise # the dollar sign is evaluated as a dollar-variable and there seem # to be no way to escape it) CREATE VIEW test.ndbinfo_dict_obj_info as SELECT id, type, version, state, parent_obj_type, parent_obj_id, fq_name FROM ndbinfo.ndb$dict_obj_info; let $table_id = `SELECT id FROM test.ndbinfo_dict_obj_info WHERE fq_name = '$_db/def/$_name'`; eval INSERT INTO $create_table_name SELECT * FROM test.ndbinfo_dict_obj_info WHERE parent_obj_id = $table_id; DROP VIEW test.ndbinfo_dict_obj_info; # Show the object list #eval select * from $create_table_name; --enable_query_log # Reset arguments let $create_table_name =; let $list_table_name =;