以下打印脚本,用msg(),调试正常,但打印不出来,请老师们指点 int main() { string sql,send_name,vc_id; vc_id=grid_get_v('MG_Item','voucher_id',1); sql="select user_name from mup_user where user_id=("; sql=sql+"select oper_user_id from ebs_v_oper_log where rec_id=("; sql=sql+"select max(rec_id) from ebs_v_oper_log where voucher_id='"+vc_id+"' and oper_type='J'))"; db_run(sql); send_name=db_res(0); //msg(send_name); return 1; };
使用多表连查或者每个select后的值再进行select。 对于打印脚本,开始要有一个db_select_dbio("data") 当查询语句结束后,要回到打印临时表,也就是在return 1前加一行: db_select_dbio("-") 否则不会达到我们的目的。
官方认证第三方服务团队 徐文标(福建-流浪) QQ:340298101 V&P :177-5046-4787 服务介绍:http://www.onlyit.cn/onlyit_service.html
main函数里只写一句 send_name='aaa' 看看效果。
只写一句 send_name='aaa',是可以的。 但用: string send_name; send_name='aaa' 就不行了。
已解决。多谢各位老师。
登录后方可发贴