| 1 | <?php |
||
| 4 | class AbstractDatabase extends \WebServCo\Framework\AbstractLibrary |
||
| 5 | { |
||
| 6 | const QUERY_TYPE_INSERT = 'INSERT'; |
||
| 7 | const QUERY_TYPE_INSERT_IGNORE = 'INSERT IGNORE'; |
||
| 8 | const QUERY_TYPE_REPLACE = 'REPLACE'; |
||
| 9 | |||
| 10 | protected $db; |
||
| 11 | protected $stmt; |
||
| 12 | protected $lastInsertId; |
||
| 13 | protected $rows; |
||
| 14 | |||
| 15 | public function __construct($config) |
||
| 19 | |||
| 20 | /** |
||
| 21 | * Get last inserted Id. |
||
| 22 | * |
||
| 23 | * https://dev.mysql.com/doc/refman/5.5/en/information-functions.html#function_last-insert-id |
||
| 24 | * If you insert multiple rows using a single INSERT statement, |
||
| 25 | * LAST_INSERT_ID() returns the value generated for the first inserted row only. |
||
| 26 | * The reason for this is to make it possible to reproduce easily the same |
||
| 27 | * INSERT statement against some other server. |
||
| 28 | */ |
||
| 29 | public function lastInsertId() |
||
| 33 | } |
||
| 34 |