dongxun4110
2017-12-05 19:33 阅读 59
已采纳

为什么我们在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 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.

    点赞 评论 复制链接分享

相关推荐