Database-PHP Connection SQL Server cannot query extra-long data using sqlsrv_fetch_array

Source: Internet
Author: User
Tags vc9
Server operating systems: Windows Server 2003
PHP Version 5.3 VC6
Database: SQL Server 2008

Assuming there are 4 fields (ID, name, content, flag) in table A, this record is not available when the content length is very long. This is what the PHP code says.

$stmt = sqlsrv_query($sql);$rs = array();where($res = sqlsrv_fetch_array($stmt)){    $rs[] = $res;}

The returned $rs is empty.

But the same code on PHP 5.4 vc9 "Local development environment, database connected server database" can be queried. So where is the configuration wrong? Or am I wrong? For advice

Reply content:

Server operating systems: Windows Server 2003
PHP Version 5.3 VC6
Database: SQL Server 2008

Assuming there are 4 fields (ID, name, content, flag) in table A, this record is not available when the content length is very long. This is what the PHP code says.

$stmt = sqlsrv_query($sql);$rs = array();where($res = sqlsrv_fetch_array($stmt)){    $rs[] = $res;}

The returned $rs is empty.

But the same code on PHP 5.4 vc9 "Local development environment, database connected server database" can be queried. So where is the configuration wrong? Or am I wrong? For advice

  • Contact Us

    The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

    If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

    A Free Trial That Lets You Build Big!

    Start building with 50+ products and up to 12 months usage for Elastic Compute Service

    • Sales Support

      1 on 1 presale consultation

    • After-Sales Support

      24/7 Technical Support 6 Free Tickets per Quarter Faster Response

    • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.