Warning: include(../lntop.php) [function.include]: failed to open stream: No such file or directory in /var/www/prime/data/www/prime-speed.ru/Manual_PHP_4/f/mysql-thread-id.html on line 19

Warning: include() [function.include]: Failed opening '../lntop.php' for inclusion (include_path='.:/usr/share/php:/usr/share/pear') in /var/www/prime/data/www/prime-speed.ru/Manual_PHP_4/f/mysql-thread-id.html on line 19

Warning: include(../levoe_menu.php) [function.include]: failed to open stream: No such file or directory in /var/www/prime/data/www/prime-speed.ru/Manual_PHP_4/f/mysql-thread-id.html on line 46

Warning: include() [function.include]: Failed opening '../levoe_menu.php' for inclusion (include_path='.:/usr/share/php:/usr/share/pear') in /var/www/prime/data/www/prime-speed.ru/Manual_PHP_4/f/mysql-thread-id.html on line 46



Учебник РНР
НазадВперёд

mysql_thread_id

(только PHP 4 CVS)

mysql_thread_id - возвращает id текущего потока.

Описание

int mysql_thread_id ([resource link_identifier])

mysql_thread_id() возвращает id текущего потока. Если соединение потеряно и вы повторно соединяетесь с помощью mysql_ping(), ID потока изменится. Это значит, что вы не должны получать и сохранять thread ID для последующего использования. Вы должны получать его по мере необходимости.

Пример 1. mysql_thread_id()
<?php
$link = mysql_connect('localhost', 'mysql_user', 'mysql_password');
$thread_id = mysql_thread_id($link);
if ($thread_id){
    printf ("current thread id is %d\n", $thread_id);
}
?>

Пример даст на выходе:
current thread id is 73

См. также mysql_ping(), mysql_list_processes().


Назад Оглавление Вперёд
mysql_tablename Вверхmysql_unbuffered_query


Warning: include(../pravoe_menu.php) [function.include]: failed to open stream: No such file or directory in /var/www/prime/data/www/prime-speed.ru/Manual_PHP_4/f/mysql-thread-id.html on line 148

Warning: include() [function.include]: Failed opening '../pravoe_menu.php' for inclusion (include_path='.:/usr/share/php:/usr/share/pear') in /var/www/prime/data/www/prime-speed.ru/Manual_PHP_4/f/mysql-thread-id.html on line 148

Rambler's Top100
© 2009 Тест скорости интернета |  Boont.Ru

Warning: include(../lnbottom.php) [function.include]: failed to open stream: No such file or directory in /var/www/prime/data/www/prime-speed.ru/Manual_PHP_4/f/mysql-thread-id.html on line 274

Warning: include() [function.include]: Failed opening '../lnbottom.php' for inclusion (include_path='.:/usr/share/php:/usr/share/pear') in /var/www/prime/data/www/prime-speed.ru/Manual_PHP_4/f/mysql-thread-id.html on line 274