select @mms_mmsid=cast(mmsid as varchar(8000)),@mms_senderaddress=senderaddress,@mms_servicecode=servicecode,@mms_vasid=cast(vasid as varchar(8000) ),
@mms_sendto=sendto,@mms_sendtime=CONVERT(varchar(100), sendtime, 25),@mms_subtime=CONVERT(varchar(100), subtime, 25),@mms_needreport=cast(needreport as varchar(10)),
@mms_subject=subject,@mms_createid=creatorid,@mms_reserve1=cast(reserve1 as varchar(100)),@mms_reserve2=reserve2 from inserted
print @mms_mmsid
set @sql='insert into '+@tblName+' values(''0'','+@mms_mmsid+','+@mms_vasid+','+@mms_servicecode+',
'''+@mms_senderaddress+''',''13899999999'','''+@mms_sendto+''','''+@mms_subtime+''','''+@mms_sendtime+''','+@mms_needreport+',
'''+@mms_subject+''',null,null,null,''2013-01-17 15:46:30.970'',''2013-01-17 15:46:30.970'',''0'',''1'',
''2'',''1'',''2013-01-31 14:50:23.107'',''123'','''+@mms_createid+''',null,null,''2013-01-31 14:50:23.107'')'
print @sql
set nocount on
--insert into fff values(@sql)
exec(@sql)