ADOdb

Database Abstraction Layer for PHP

User Tools

Site Tools


v5:reference:connection:getall

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Next revision
Previous revision
reference:getall [2015/07/21 16:47] – created mnewnhamv5:reference:connection:getall [2019/05/08 16:41] (current) – ADODB_ASSOC_CASE not $ADODB_ASSOC_CASE dregad
Line 1: Line 1:
 ====== getAll ====== ====== getAll ======
 ~~NOTOC~~ ~~NOTOC~~
 +<WRAP important>
 +This function and [[v5:reference:connection:getarray|getArray()]] produce the same output. The functions may be merged in future releases.
 +</WRAP>
 <WRAP right box> <WRAP right box>
 == syntax == == syntax ==
Line 10: Line 13:
  
 ===== Description ===== ===== Description =====
-The function executes a statement and returns a the entire recordset in an array or false if the statement execution fails. The presentation of the returned data can be modified by the variables [[reference:adodb_fetch_mode|$ADODB_FETCH_MODE]]  and [[reference:adodb_assoc_case|$ADODB_ASSOC_CASE]] and the function [[reference:setfetchmode|setFetchMode()]].+The function executes a statement and returns a the entire recordset in an array or false if the statement execution fails. If no records match the provided SQL statement, an empty array is returned. 
 + 
 +The presentation of the returned data can be modified by:   
 +  * [[v5:reference:adodb_fetch_mode|$ADODB_FETCH_MODE]] variable, 
 +  [[v5:reference:adodb_assoc_case|ADODB_ASSOC_CASE]] constant, 
 +  * [[v5:reference:connection:setfetchmode|setFetchMode()]] function.
  
-For a detailed description of the parameters passed, see [[reference:execute|execute()]].+For a detailed description of the parameters passed, see [[v5:reference:connection:execute|execute()]].
  
 ==== Usage ==== ==== Usage ====
Line 19: Line 27:
  * DB2 Connection assumed  * DB2 Connection assumed
 */ */
-$ar = $db->execute("SELECT * FROM ACT");+$ar = $db->getAll("SELECT * FROM ACT");
  
 /* /*
v5/reference/connection/getall.1437490035.txt.gz · Last modified: 2017/04/21 11:35 (external edit)