dongxun4110 2017-12-05 19:33 采纳率: 0%
浏览 137
已采纳

为什么我们在php中使用mysqli_poll()函数?

I am totally new to php and mysql. Please can anyone tell why we use mysqli_poll() function in php ?

I found 2 questions on stack overflow:
1) How does mysqli_poll work?
2) mysqli_poll() - what's the third parameter for?

But both are different from my question. In fact i have read them but unable to understand.

Currently i am on php.net for this function and trying to understand the examples but i am too much depressed and failed to understand.

Please can anyone tell me in easy and beginners level, that what is the use of this function in php and mysql. What is means by poll in the sense of mysql database ?

Thanks in advance !!!

  • 写回答

1条回答 默认 最新

  • duanhui5344 2017-12-05 19:53
    关注

    I have a feeling this is a wrapper around a POSIX-style select call, or something similar in nature, that's used to efficiently poll multiple handles for data that can be read.

    Normally select-driven code is deemed to be "polling" when it checks for data ready to be read or handles ready to be written to.

    It's unlikely that most programmers have ever used this function. It has very narrow use cases, you must be juggling a non-trivial number of MySQL handles at once. Most applications use a handful, and often with a connection pool.

    本回答被题主选为最佳回答 , 对您是否有帮助呢?
    评论

报告相同问题?