时间:2021-07-01 10:21:17 帮助过:3人阅读
mysql> create function LocateWords -> (s CHAR(20),t CHAR(20)) -> RETURNS int(11) -> return locate(t,s); mysql> select LocateWords(‘abcdabcaba‘,‘da‘);
mysql> CREATE FUNCTION Fun_GetQuesCntByClass -> ( -> c bigint -> ) -> returns int -> begin -> declare x int; -> select count(1) into x from Ques where classid=c; -> return (x); -> end; mysql> select Fun_GetQuesCntByClass(1);
本文出自 “sukun” 博客,请务必保留此出处http://sukunwu.blog.51cto.com/10453116/1688341
MySQL函数
标签:mysql 函数