Home  >  Article  >  Backend Development  >  cakephp开发中遇到的有关问题

cakephp开发中遇到的有关问题

WBOY
WBOYOriginal
2016-06-13 09:59:36912browse

cakephp开发中遇到的问题
for($i=0;$i$result = $this->query("select uuid() as total");
print_r($result);
}
我是在cakephp 下运行的,为什么打印的5条记录的结果都是一样的?请高手回答

------解决方案--------------------
这得看cakephp的query()方法是怎么封装的了,他有可能跟缓存有关,如果将执行的sql跟以前执行过的sql相等,它就直接将以前的结果拿出来了,我是猜的哈,坐等正确答案
------解决方案--------------------
sql 指令是一样的,自然结果也就一样
否则就完蛋了

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn