| Manuál PHP | ||
|---|---|---|
| PÅ™edcházejÃcà | Kapitola 45. PDO Driver How-To | Dalšà |
pdo_stmt_t definition
All fields should be treated as read-only unless explicitly stated otherwise.
Obrázek 45-2. pdo_stmt_t

- The driver must set this during SKEL_handle_preparer().

- This item is for use by the driver; the intended usage is to store a pointer (during SKEL_handle_factory()) to whatever instance data is required to maintain a connection to the database.

- This is set by PDO after the statement has been executed for the first time. Your driver can inspect this value to determine if it can skip one-time actions as an optimization.

- Discussed in more detail in „SKEL_handle_preparer“

- Your driver is responsible for setting this field to the number of columns available in a result set. This is usually set during SKEL_stmt_execute() but with some database implementations, the column count may not be available until SKEL_stmt_fetch() has been called at least once. Drivers that SKEL_stmt_next_rowset() should update the column count when a new rowset is available.

-
PDO will allocate this field based on the value that you set for the
column count. You are responsible for populating each column during
SKEL_stmt_describe(). You must set the
precision,maxlen,name,namelenandparam_typemembers for each column. Thenameis expected to be allocated using emalloc(); PDO will efree() at the appropriate time.
| PÅ™edcházejÃcà | Domů | Dalšà |
| pdo_dbh_t definition | Nahoru< |