Lines Matching refs:pgsql_result
1845 PGresult *pgsql_result; local
1869 while ((pgsql_result = PQgetResult(pgsql))) {
1870 PQclear(pgsql_result);
1876 pgsql_result = PQexec(pgsql, query);
1878 PQclear(pgsql_result);
1880 pgsql_result = PQexec(pgsql, query);
1883 if (pgsql_result) {
1884 status = PQresultStatus(pgsql_result);
1895 PQclear(pgsql_result);
1900 if (pgsql_result) {
1903 pg_result->result = pgsql_result;
1907 PQclear(pgsql_result);
1947 PGresult *pgsql_result; local
1972 while ((pgsql_result = PQgetResult(pgsql))) {
1973 PQclear(pgsql_result);
2007 pgsql_result = PQexecParams(pgsql, query, num_params,
2010 PQclear(pgsql_result);
2012 pgsql_result = PQexecParams(pgsql, query, num_params,
2016 if (pgsql_result) {
2017 status = PQresultStatus(pgsql_result);
2030 PQclear(pgsql_result);
2035 if (pgsql_result) {
2038 pg_result->result = pgsql_result;
2042 PQclear(pgsql_result);
2063 PGresult *pgsql_result; local
2088 while ((pgsql_result = PQgetResult(pgsql))) {
2089 PQclear(pgsql_result);
2095 pgsql_result = PQprepare(pgsql, stmtname, query, 0, NULL);
2097 PQclear(pgsql_result);
2099 pgsql_result = PQprepare(pgsql, stmtname, query, 0, NULL);
2102 if (pgsql_result) {
2103 status = PQresultStatus(pgsql_result);
2114 PQclear(pgsql_result);
2119 if (pgsql_result) {
2122 pg_result->result = pgsql_result;
2126 PQclear(pgsql_result);
2150 PGresult *pgsql_result; local
2175 while ((pgsql_result = PQgetResult(pgsql))) {
2176 PQclear(pgsql_result);
2204 pgsql_result = PQexecPrepared(pgsql, stmtname, num_params,
2207 PQclear(pgsql_result);
2209 pgsql_result = PQexecPrepared(pgsql, stmtname, num_params,
2213 if (pgsql_result) {
2214 status = PQresultStatus(pgsql_result);
2227 PQclear(pgsql_result);
2232 if (pgsql_result) {
2235 pg_result->result = pgsql_result;
2239 PQclear(pgsql_result);
2257 PGresult *pgsql_result; local
2268 pgsql_result = pg_result->result;
2272 RETVAL_LONG(PQntuples(pgsql_result));
2275 RETVAL_LONG(PQnfields(pgsql_result));
2279 RETVAL_LONG(atoi(PQcmdTuples(pgsql_result)));
2534 PGresult *pgsql_result; local
2547 pgsql_result = pg_result->result;
2549 if (field < 0 || field >= PQnfields(pgsql_result)) {
2556 RETURN_STRING(PQfname(pgsql_result, (int)field));
2559 RETURN_LONG(PQfsize(pgsql_result, (int)field));
2562 …char *name = get_field_name(pg_result->conn, PQftype(pgsql_result, (int)field), &EG(regular_list));
2569 oid = PQftype(pgsql_result, (int)field);
2627 PGresult *pgsql_result; local
2638 pgsql_result = pg_result->result;
2640 RETURN_LONG(PQfnumber(pgsql_result, field));
2650 PGresult *pgsql_result; local
2668 pgsql_result = pg_result->result;
2674 if (pgsql_row >= PQntuples(pgsql_result)) {
2679 if (row < 0 || row >= PQntuples(pgsql_result)) {
2688 field_offset = PQfnumber(pgsql_result, Z_STRVAL_P(field));
2689 if (field_offset < 0 || field_offset >= PQnfields(pgsql_result)) {
2696 if (Z_LVAL_P(field) < 0 || Z_LVAL_P(field) >= PQnfields(pgsql_result)) {
2704 if (PQgetisnull(pgsql_result, pgsql_row, field_offset)) {
2707 RETVAL_STRINGL(PQgetvalue(pgsql_result, pgsql_row, field_offset),
2708 PQgetlength(pgsql_result, pgsql_row, field_offset));
2717 PGresult *pgsql_result; local
2767 pgsql_result = pg_result->result;
2770 if (row < 0 || row >= PQntuples(pgsql_result)) {
2780 if (pgsql_row < 0 || pgsql_row >= PQntuples(pgsql_result)) {
2787 for (i = 0, num_fields = PQnfields(pgsql_result); i < num_fields; i++) {
2788 if (PQgetisnull(pgsql_result, pgsql_row, i)) {
2793 field_name = PQfname(pgsql_result, i);
2797 char *element = PQgetvalue(pgsql_result, pgsql_row, i);
2806 field_name = PQfname(pgsql_result, i);
2913 PGresult *pgsql_result; local
2929 pgsql_result = pg_result->result;
2931 if (php_pgsql_result2array(pgsql_result, return_value, result_type) == FAILURE) {
2943 PGresult *pgsql_result; local
2957 pgsql_result = pg_result->result;
2959 num_fields = PQnfields(pgsql_result);
2967 if ((pg_numrows = PQntuples(pgsql_result)) <= 0) {
2972 if (PQgetisnull(pgsql_result, pg_row, (int)colno)) {
2975 add_next_index_string(return_value, PQgetvalue(pgsql_result, pg_row, (int)colno));
3016 PGresult *pgsql_result; local
3034 pgsql_result = pg_result->result;
3040 if (pgsql_row < 0 || pgsql_row >= PQntuples(pgsql_result)) {
3044 if (row < 0 || row >= PQntuples(pgsql_result)) {
3055 field_offset = PQfnumber(pgsql_result, Z_STRVAL_P(field));
3056 if (field_offset < 0 || field_offset >= PQnfields(pgsql_result)) {
3063 if (Z_LVAL_P(field) < 0 || Z_LVAL_P(field) >= PQnfields(pgsql_result)) {
3073 RETVAL_LONG(PQgetlength(pgsql_result, pgsql_row, field_offset));
3076 RETVAL_LONG(PQgetisnull(pgsql_result, pgsql_row, field_offset));
3123 PGresult *pgsql_result; local
3137 pgsql_result = pg_result->result;
3139 oid = PQoidValue(pgsql_result);
3145 Z_STRVAL_P(return_value) = (char *) PQoidStatus(pgsql_result);
4104 PGresult *pgsql_result; local
4129 while ((pgsql_result = PQgetResult(pgsql))) {
4130 PQclear(pgsql_result);
4132 pgsql_result = PQexec(pgsql, query);
4138 if (pgsql_result) {
4139 status = PQresultStatus(pgsql_result);
4146 if (pgsql_result) {
4152 PQclear(pgsql_result);
4215 while ((pgsql_result = PQgetResult(pgsql))) {
4216 PQclear(pgsql_result);
4219 PQclear(pgsql_result);
4224 PQclear(pgsql_result);
4243 PGresult *pgsql_result; local
4266 while ((pgsql_result = PQgetResult(pgsql))) {
4267 PQclear(pgsql_result);
4269 pgsql_result = PQexec(pgsql, query);
4276 if (pgsql_result) {
4277 status = PQresultStatus(pgsql_result);
4284 if (pgsql_result) {
4286 PQclear(pgsql_result);
4340 while ((pgsql_result = PQgetResult(pgsql))) {
4341 if (PGRES_COMMAND_OK != PQresultStatus(pgsql_result)) {
4345 PQclear(pgsql_result);
4351 PQclear(pgsql_result);
4357 PQclear(pgsql_result);
4661 PGresult *pgsql_result; local
4674 pgsql_result = pg_result->result;
4675 if (!pgsql_result) {
4678 err = (char *)PQresultErrorMessage(pgsql_result);
4690 PGresult *pgsql_result; local
4703 pgsql_result = pg_result->result;
4704 if (!pgsql_result) {
4717 field = (char *)PQresultErrorField(pgsql_result, (int)fieldcode);
4827 PGresult *pgsql_result; local
4849 while ((pgsql_result = PQgetResult(pgsql))) {
4850 PQclear(pgsql_result);
5241 PGresult *pgsql_result; local
5252 pgsql_result = PQgetResult(pgsql);
5253 if (!pgsql_result) {
5259 pg_result->result = pgsql_result;
5272 PGresult *pgsql_result; local
5284 pgsql_result = pg_result->result;
5286 status = PQresultStatus(pgsql_result);
5290 RETURN_STRING(PQcmdStatus(pgsql_result));