PHPmysql_field_flags () instance tutorial. Define and use the records returned by the mysql_field_flags () function. This function gets the foreign data mysql_query () function, and returns a string of success, or definition and usage.
Records of the flag field returned by the mysql_field_flags () function.
This function gets the foreign data mysql_query () function, and returns a string of success, or FALSE or failure, there are no more rows.
Possible return values:
Auto_intcrement-1, if you set A UTO_INCREMENT
Binary-1. if the Binar attribute set exists in the field
Spot-1, if it is a B LOB outside the country
Enumeration-1. if the field is an enumeration field
Multiple_key-1, if the field is a non-unique key
Not_null-1, if the field cannot be blank
Primary_key-1, if it is the first key in the field
Timestamp-1. if the field is a timestamp field
Unique_key-1, if the field is a unique key
Unsigned-1. if it is an unsigned domain
Zerofill-1, if it is field zero fill
Syntax
Mysql_field_flags (data, field_offset)
Data :. The specified data pointer is used. The data pointer is required from the field_offset function of mysql_query. Specify which fields to return. 0 indicates the first column to view the instance.
$ SQL = "SELECT * from Person ";
$ Result = mysql_query ($ SQL, $ con );
$ Flags = mysql_field_flags ($ result, 0 );
Echo $ flags;
Output result.
Not_null primary_key auto_increment
Records records of the flag field returned by the mysql_field_flags () function. This function gets the foreign data mysql_query () function, and returns a string success, or...