Documentation Home
Connectors and APIs Manual
Download this Manual

Connectors and APIs Manual  /  ...  /  The mysqli_result class

7.3.11 The mysqli_result class

Copyright 1997-2020 the PHP Documentation Group.

Represents the result set obtained from a query against the database.


Table 7.16 Changelog

5.4.0Iterator support was added, as mysqli_result now implements Traversable.

 mysqli_result {
mysqli_result , Traversable Properties  int mysqli_result->current_field ;
  int mysqli_result->field_count ;
  array mysqli_result->lengths ;
  int mysqli_result->num_rows ;
Methods  public bool mysqli_result::data_seek(int offset);
  public mixed mysqli_result::fetch_all(int resulttype= =MYSQLI_NUM);
  public mixed mysqli_result::fetch_array(int resulttype= =MYSQLI_BOTH);
  public array mysqli_result::fetch_assoc();
  public object mysqli_result::fetch_field_direct(int fieldnr);
  public object mysqli_result::fetch_field();
  public array mysqli_result::fetch_fields();
  public object mysqli_result::fetch_object(string class_name= ="stdClass",
                                            array params);

  public mixed mysqli_result::fetch_row();
  public bool mysqli_result::field_seek(int fieldnr);
  public void mysqli_result::free();
  public void mysqli_result::close();
  public void mysqli_result::free_result();