Home >Backend Development >PHP Tutorial > odbc_fetch_array()如何用

odbc_fetch_array()如何用

WBOY
WBOYOriginal
2016-06-13 13:21:372410browse

odbc_fetch_array()怎么用

PHP code
<!--

Code highlighting produced by Actipro CodeHighlighter (freeware)
http://www.CodeHighlighter.com/

-->
while($row=odbc_fetch_array($result))
{}


这样获得的结果集不是一个数组吗,为什么echo $row[0];什么都不显示,必须用字段名称才可以显示,echo $row[Time]这样才行。能否用下标控制?

------解决方案--------------------
探讨

引用:

echo '
';print_r($row);exit;<br><br>这样打出来不就知道了吗<br><br>这样打出来没有下标形式的,全是字段名称式的。<br>

------解决方案--------------------
odbc_fetch_array ― Fetch a result row as an associative array
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