Execute($sql); I was expecting a result set to be returned. However, execute returns "False""> PHP and ADODB execution calls return false-PHP Chinese Network Q&A
PHP and ADODB execution calls return false
P粉274161593
P粉274161593 2023-08-31 22:22:55
0
1
386

I'm using ADODB 5.21.2 and PHP 7.4. I get the error "Command out of sync; you cannot run this command now when executing a query. My database is MySQL 5.7 and I am using the mysqli driver. This problem only occurs on one of my servers. The query works Running on 10 other servers. Confused. Any help would be greatly appreciated. Call the execute method to execute the insert SQL.

$rs = $glb_dbconn->Execute($sql);

I am expecting a result set to be returned. However, the execution returns "false". I also tried running a select query that actually returns a result set. Even this fails with the same error.

P粉274161593
P粉274161593

reply all (1)
P粉445714413

This was discussed in the

ADOdb support chaton Gitter.

Users report that the issue is caused by a bug in their code, possibly due to executing a new query without using the results of the previous query, as

MySQL Documentation.

    Latest Downloads
    More>
    Web Effects
    Website Source Code
    Website Materials
    Front End Template
    About us Disclaimer Sitemap
    php.cn:Public welfare online PHP training,Help PHP learners grow quickly!