mysql存储过程
BEGIN
DECLARE orderNo varchar(100) DEFAULT null;
select order_no into orderNo from t_orderpay where order_no=p2 and step='2';
if orderNo <>'' and left(orderNo,3)='JXS'
then
insert into t_message(mtype,title,createtime) VALUES(p1,'测试',now());
END IF ;
END