delimiter //
drop procedure if exists createflowtable_UL//
create procedure createflowtable_UL () BEGIN
declare tablesql varchar(300);
declare timesql varchar(20);
set timesql = CONCAT (MONTH (now()),'-',DAY (now()),'_',hour (now()));
set tablesql = CONCAT ('create table flow_agent8_job2_UL_',timesql,
'( ULthroughput FLOAT(12,4),',
'max_rate FLOAT(12,8),',
'eNB VARCHAR(20) )',
' ENGINE=MyISAM DEFAULT CHARSET=latin1');
set @s := tablesql;
prepare statement from @s;
execute statement;
END
//
delimiter ;
调用该存储过程时,怎么生成不了表?
drop procedure if exists createflowtable_UL//
create procedure createflowtable_UL () BEGIN
declare tablesql varchar(300);
declare timesql varchar(20);
set timesql = CONCAT (MONTH (now()),'-',DAY (now()),'_',hour (now()));
set tablesql = CONCAT ('create table flow_agent8_job2_UL_',timesql,
'( ULthroughput FLOAT(12,4),',
'max_rate FLOAT(12,8),',
'eNB VARCHAR(20) )',
' ENGINE=MyISAM DEFAULT CHARSET=latin1');
set @s := tablesql;
prepare statement from @s;
execute statement;
END
//
delimiter ;
调用该存储过程时,怎么生成不了表?
解决方案 »
- 请教:C/S架构的局或网软件,服务器安装了mysql也配置了,在客户端只是调用服务器端的mysql数据?
- 求一个SELECT-SQL语句
- 如何计算一个mysql进程最大占用的资源呢?
- 如何统计特定范围内的记录条数?
- 单表求平均数并进行排序,越简单的语句越好,请大家指教。
- 采用mysql开发的数据库应用程序,在安装到其他电脑上的时候,可以不安装mysql,而把mysql数据库当成一个文件连接到应用程序中使用吗?就
- mysql中的datatime对应c语言中的什么数据类型,time_t 还是其他什么的?
- mysql数据库的一个表最多能有多少列?
- 求助!一个简单的问题!
- 登录不进去,是什么原因?
- MYsql 怎么约束列的取值范围
- MYsql 怎么约束列的取值范围
drop procedure if exists createflowtable_UL//
create procedure createflowtable_UL () BEGIN
declare tablesql varchar(300);
declare timesql varchar(20);
set timesql = CONCAT (MONTH (now()),'-',DAY (now()),'_',hour (now()));
set tablesql = CONCAT ('`create table flow_agent8_job2_UL_',timesql,
'`( ULthroughput FLOAT(12,4),',
'max_rate FLOAT(12,8),',
'eNB VARCHAR(20) )',
' ENGINE=MyISAM DEFAULT CHARSET=latin1;');
set @s := tablesql;
prepare statement from @s;
execute statement;
END
//
delimiter ;
drop procedure if exists createflowtable_UL//
create procedure createflowtable_UL () BEGIN
declare tablesql varchar(300);
declare timesql varchar(20);
set timesql = CONCAT (MONTH (now()),'-',DAY (now()),'_',hour (now()));
set tablesql = CONCAT ('`create table flow_agent8_job2_UL_',timesql,
'`( ULthroughput FLOAT(12,4),',
'max_rate FLOAT(12,8),',
'eNB VARCHAR(20) )',
' ENGINE=MyISAM DEFAULT CHARSET=latin1;');
set @s := tablesql;
select @sql;
prepare statement from @s;
execute statement;
END
//
delimiter ;