写好的一个存储过程TS_Pro_AddMyBrowse 有返回参数
begin declare d_row int default 0; start TRANSACTION; insert into ts_mybrowse(UserID,ArticleID,FromUserID,ArticleTitle,BrowsingTime) values(UserID,ArticleID,FromUserID,ArticleTitle,BrowsingTime); select ROW_COUNT() into d_row; if(d_row>0) then set ReturnValuex=1; commit; else set ReturnValuex=-1; rollback; end if; end
新建查询:
CALL TS_Pro_AddMyBrowse(@1,‘1000017‘,‘883‘,‘113505‘,‘趣味物理大全‘,‘2016-02-17 11:41:42‘)
[SQL] CALL TS_Pro_AddMyBrowse(@1,‘1000017‘,‘883‘,‘113505‘,‘趣味物理大全‘,‘2016-02-17 11:41:42‘)
受影响的行: 0
时间: 0.155s
时间: 2024-10-20 04:44:26