就这段语句,能不能帮我转换成Mysql语句(最好不用存储过程)
select 'alter table '|| TABLE_NAME ||' add (
EXT_DMSN_NO_11 VARCHAR2(32) default ''#NULL#'' not null,
EXT_DMSN_NO_12 VARCHAR2(32) default ''#NULL#'' not null,
EXT_DMSN_NO_13 VARCHAR2(32) default ''#NULL#'' not null,
EXT_DMSN_NO_14 VARCHAR2(32) default ''#NULL#'' not null,
EXT_DMSN_NO_15 VARCHAR2(32) default ''#NULL#'' not null,
EXT_DMSN_NO_16 VARCHAR2(32) default ''#NULL#'' not null,
EXT_DMSN_NO_17 VARCHAR2(32) default ''#NULL#'' not null,
EXT_DMSN_NO_18 VARCHAR2(32) default ''#NULL#'' not null,
EXT_DMSN_NO_19 VARCHAR2(32) default ''#NULL#'' not null,
EXT_DMSN_NO_20 VARCHAR2(32) default ''#NULL#'' not null)
GO'
from all_tables
where OWNER='BM_2018'
and TABLE_NAME like 'BM_BUDGETEERING_T_R%'
select concat(concat('alter table ', t.TABLE_NAME), '
add COLUMN EXT_DMSN_NO_11 VARCHAR2(32) default ''#NULL#'' not null,
add COLUMN EXT_DMSN_NO_12 VARCHAR2(32) default ''#NULL#'' not null,
add COLUMN EXT_DMSN_NO_13 VARCHAR2(32) default ''#NULL#'' not null,
add COLUMN EXT_DMSN_NO_14 VARCHAR2(32) default ''#NULL#'' not null,
add COLUMN EXT_DMSN_NO_15 VARCHAR2(32) default ''#NULL#'' not null,
add COLUMN EXT_DMSN_NO_16 VARCHAR2(32) default ''#NULL#'' not null,
add COLUMN EXT_DMSN_NO_17 VARCHAR2(32) default ''#NULL#'' not null,
add COLUMN EXT_DMSN_NO_18 VARCHAR2(32) default ''#NULL#'' not null,
add COLUMNEXT_DMSN_NO_19 VARCHAR2(32) default ''#NULL#'' not null,
add COLUMN EXT_DMSN_NO_20 VARCHAR2(32) default ''#NULL#'' not null ;') from information_schema.TABLES
t where t.TABLE_SCHEMA = 'test' and t.TABLE_NAME like 'BM_BUDGETEERING_T_R%';
test 是 数据库名 , 至于owner ,mysql 和oracle不一样,没有用户表空间和模式