PHP mysql_info() ফাংশন

সংজ্ঞা ও ব্যবহার

mysql_info() ফাংশন সর্বশেষ প্রশ্নাত্মক তথ্য ফিরিয়ে দেয়。

সফল হলে, সেই বিন্যাসটির বিষয়ে তথ্য ফিরিয়ে দেয়, অসফল হলে false ফিরিয়ে দেয়。

গঠন

mysql_info(connection)
প্রামর্শ বর্ণনা
connection বাছাইয়াত। মাইক্রোসফট কানেকশন নির্দিষ্ট করুন। যদি নির্দিষ্ট না হয়, তবে আগের কানেকশন ব্যবহার করা হবে。

description

mysql_info() returns through the given connection details of the latest query performed. If not specified connectionAssumed to be the last opened connection.

mysql_info() returns a string for all the following statements listed:

INSERT INTO ... SELECT ...
INSERT INTO ... VALUES (...),(...),(...)...
LOAD DATA INFILE ...
ALTER TABLE
UPDATE

Returns false for any other statement. The format of the string depends on the given statement.

Example

<?php
$con = mysql_connect("localhost", "hello", "321");
if (!$con)
  {
  die('Could not connect: ' . mysql_error());
  }
$db_selected = mysql_select_db("test_db",$con);
$sql = "INSERT INTO person VALUES ('Bill','Gates','Utah','19')";
$result = mysql_query($sql,$con);
$info = mysql_info($con);
echo $info;
mysql_close($con);
?>

Output similar to:

String format: Records: 15 Duplicates: 0 Warnings: 0