function Split(szFullString, szSeparator) local nFindStartIndex = local nSplitIndex = local nSplitArray = {} while true do local nFindLastIndex = string.find(szFullString, szSeparator, nFindStartIndex) if not nFindLastIndex then nSplitArray[nSplitInd…
declare @str varchar(100),@sql varchar(1000)set @str='1,2,3,4,5,6,7,8,9,10'set @sql='select Value='''+ replace(@str,',',''' union all select ''')+''''PRINT @sqlexec (@sql) if exists (select * from dbo.sysobjects where id = object_id(N'[dbo].[f_spli…
DROP FUNCTION IF EXISTS `getSplitName`$$ )) RETURNS text BEGIN /* 对逗号进行分离的字符串,分割出'登陆名_用户名/部门名'中的_后部门字符串,以逗号拼接 例:"admin_管理员1,admin_管理员2,admin_管理员3,admin_管理员4,admin_管理员5"这种格式的字符串,调用func_get_name(str,"_") 可得到"管理员1,管理员2,管理员3,管理员4,管理员5…