diff options
author | George Schlossnagle <gschlossnagle@php.net> | 2004-05-18 18:01:52 +0000 |
---|---|---|
committer | George Schlossnagle <gschlossnagle@php.net> | 2004-05-18 18:01:52 +0000 |
commit | 71728cc2b24c4053aa7794a4f27b6403868dbd85 (patch) | |
tree | 04754869301b13587162d4d7313e9466b53d1097 /ext/pdo_mysql/php_pdo_mysql_int.h | |
parent | da26db30543c97c485424030054471d2daffce64 (diff) | |
download | php-git-71728cc2b24c4053aa7794a4f27b6403868dbd85.tar.gz |
initial import of mysql 3.x pdo driver
Diffstat (limited to 'ext/pdo_mysql/php_pdo_mysql_int.h')
-rwxr-xr-x | ext/pdo_mysql/php_pdo_mysql_int.h | 61 |
1 files changed, 61 insertions, 0 deletions
diff --git a/ext/pdo_mysql/php_pdo_mysql_int.h b/ext/pdo_mysql/php_pdo_mysql_int.h new file mode 100755 index 0000000000..92a988e957 --- /dev/null +++ b/ext/pdo_mysql/php_pdo_mysql_int.h @@ -0,0 +1,61 @@ +/* + +----------------------------------------------------------------------+ + | PHP Version 5 | + +----------------------------------------------------------------------+ + | Copyright (c) 1997-2004 The PHP Group | + +----------------------------------------------------------------------+ + | This source file is subject to version 3.0 of the PHP license, | + | that is bundled with this package in the file LICENSE, and is | + | available through the world-wide-web at the following url: | + | http://www.php.net/license/3_0.txt. | + | If you did not receive a copy of the PHP license and are unable to | + | obtain it through the world-wide-web, please send a note to | + | license@php.net so we can mail you a copy immediately. | + +----------------------------------------------------------------------+ + | Author: George Schlossnagle <george@omniti.com> | + +----------------------------------------------------------------------+ +*/ + +/* $Id$ */ + +#ifndef PHP_PDO_MYSQL_INT_H +#define PHP_PDO_MYSQL_INT_H + +#include <mysql.h> + +/* stuff we use in an OCI database handle */ +typedef struct { + MYSQL *server; + unsigned int last_err; + unsigned attached:1; + unsigned _reserved:31; +} pdo_mysql_db_handle; + +typedef struct { + MYSQL_FIELD *def; +} pdo_mysql_column; + +typedef struct { + pdo_mysql_db_handle *H; + MYSQL_RES *result; + MYSQL_ROW current_data; + long *current_lengths; + unsigned int last_err; + pdo_mysql_column *cols; +} pdo_mysql_stmt; + +typedef struct { + char *repr; + long repr_len; + int mysql_type; + void *thing; /* for LOBS, REFCURSORS etc. */ +} pdo_mysql_bound_param; + +extern pdo_driver_t pdo_mysql_driver; + +int _mysql_error(char *what, int errno, const char *file, int line TSRMLS_DC); +#define pdo_mysql_error(w,s) _mysql_error(w, s, __FILE__, __LINE__ TSRMLS_CC) +int mysql_handle_error(pdo_dbh_t *dbh, pdo_mysql_db_handle *H, int errcode); + +extern struct pdo_stmt_methods mysql_stmt_methods; +#endif |