Skip to content

Commit b5991bd

Browse files
authored
Merge pull request #160 from hubaishan/fixpgsql
fixBug: Creating default object from empty value in pgsql
2 parents f3d22c2 + 5fd2303 commit b5991bd

1 file changed

Lines changed: 1 addition & 0 deletions

File tree

lib/Database/ez_pgsql.php

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -204,6 +204,7 @@ private function processQueryResult(string $query, $result = null)
204204
// Take note of column info
205205
$i = 0;
206206
while ($i < @\pg_num_fields($this->result)) {
207+
$this->col_info[$i] = new \stdClass();
207208
$this->col_info[$i]->name = \pg_field_name($this->result, $i);
208209
$this->col_info[$i]->type = \pg_field_type($this->result, $i);
209210
$this->col_info[$i]->size = \pg_field_size($this->result, $i);

0 commit comments

Comments
 (0)