谢谢楼上朋友的解答。cast是转换, 但是前面的select * from table()这是什么意思,
见识浅,没见过这种用法 --我一般用的转换用法 select '123',cast('123' as int),convert(int,'123')
在oracle的存储过程今天才见这种用法,我拿出来单独执行就报ORA-22905搞不清楚是怎么回事。这是函数源代码:for rec in ( select * from Issues where TypeID in ( select * from TABLE(cast(projectTypes as IntArray)) ) ) loop historicProject := historicProjectID(rec.ID, -8, time); if historicProject = ourProject then return rec.ID; end if; end loop;
--我一般用的转换用法
select '123',cast('123' as int),convert(int,'123')
select * from Issues
where TypeID in (
select * from TABLE(cast(projectTypes as IntArray))
)
)
loop
historicProject := historicProjectID(rec.ID, -8, time);
if historicProject = ourProject then
return rec.ID;
end if;
end loop;
我搜了下 有搜到说是 9i 的bug的
友情提示,可以把这个发到sqlserver版去问问。
学习了
百度了一下
有这个帖子 楼主可以看一下~
http://www.hackvip.com/article/sort0132/sort0165/Hackvip_192761.html