PHP mSQL Functions

EditRocket provides the following information on mSQL functions in the PHP source code builder.

-

int msql_affected_rows ( resource $result ) - Returns number of affected rows by the last SELECT, UPDATE or DELETE query associated with result.

bool msql_close ([ resource $link_identifier ] ) - msql_close() closes the non-persistent connection to the mSQL server that's associated with the specified link identifier.

resource msql_connect ([ string $hostname ] ) - msql_connect() establishes a connection to a mSQL server.

bool msql_create_db ( string $database_name [, resource $link_identifier ] ) - msql_create_db() attempts to create a new database on the mSQL server.

-

bool msql_data_seek ( resource $result , int $row_number ) - msql_data_seek() moves the internal row pointer of the mSQL result associated with the specified query identifier to point to the specified row number.

resource msql_db_query ( string $database , string $query [, resource $link_identifier ] ) - msql_db_query() selects a database and executes a query on it.

-

bool msql_drop_db ( string $database_name [, resource $link_identifier ] ) - msql_drop_db() attempts to drop (remove) a database from the mSQL server.

string msql_error ( void ) - msql_error() returns the last issued error by the mSQL server. Note that only the last error message is accessible with msql_error().

array msql_fetch_array ( resource $result [, int $result_type ] ) -

object msql_fetch_field ( resource $result [, int $field_offset ] ) - msql_fetch_field() can be used in order to obtain information about fields in a certain query result.

object msql_fetch_object ( resource $result ) -

array msql_fetch_row ( resource $result ) - msql_fetch_row() fetches one row of data from the result associated with the specified query identifier. The row is returned as an array. Each result column is stored in an array offset, starting at offset 0.

string msql_field_flags ( resource $result , int $field_offset ) - msql_field_flags() returns the field flags of the specified field.

int msql_field_len ( resource $result , int $field_offset ) - msql_field_len() returns the length of the specified field.

string msql_field_name ( resource $result , int $field_offset ) - msql_field_name() gets the name of the specified field index.

bool msql_field_seek ( resource $result , int $field_offset ) - Seeks to the specified field offset.

int msql_field_table ( resource $result , int $field_offset ) - Returns the name of the table that the specified field is in.

string msql_field_type ( resource $result , int $field_offset ) - msql_field_type() gets the type of the specified field index.

-

-

-

-

-

bool msql_free_result ( resource $result ) - msql_free_result() frees the memory associated with query_identifier. When PHP completes a request, this memory is freed automatically, so you only need to call this function when you want to make sure you don't use too much memory while the script is running.

resource msql_list_dbs ([ resource $link_identifier ] ) -

resource msql_list_fields ( string $database , string $tablename [, resource $link_identifier ] ) - msql_list_fields() returns information about the given table.

resource msql_list_tables ( string $database [, resource $link_identifier ] ) - msql_list_tables() lists the tables on the specified database.

int msql_num_fields ( resource $result ) - msql_num_fields() returns the number of fields in a result set.

int msql_num_rows ( resource $query_identifier ) - msql_num_rows() returns the number of rows in a result set.

-

-

resource msql_pconnect ([ string $hostname ] ) -

resource msql_query ( string $query [, resource $link_identifier ] ) - msql_query() sends a query to the currently active database on the server that's associated with the specified link identifier.

-

string msql_result ( resource $result , int $row [, mixed $field ] ) - msql_result() returns the contents of one cell from a mSQL result set.

bool msql_select_db ( string $database_name [, resource $link_identifier ] ) - msql_select_db() sets the current active database on the server that's associated with the specified link_identifier.

-