dataobjects: postgresql createtables error

From: Date: Mon, 24 Jan 2005 10:26:00 +0000
Subject: dataobjects: postgresql createtables error
Groups: php.pear.general 
Request: Send a blank email to pear-general+get-17123@lists.php.net to get a copy of this message
Hi, When running createtables.php on my postgresql 7.4 database I get the following error: [jeroen@respect config]$ php /usr/local/share/php/pear/DB/DataObject/createTables.php DataObjects_comp05.ini
DB_DataObject_Generator   : 0       : CREATING FOR compendium2005
PHP Notice: Trying to get property of non-object in /usr/local/share/php/pear/DB/pgsql.php on line 729 Notice: Trying to get property of non-object in /usr/local/share/php/pear/DB/pgsql.php on line 729 [db_error: message="DB Error: insufficient data supplied" code=-20 mode=return level=notice prefix="" info="SELECT c.relname as "Name"
                       FROM pg_class c, pg_user u
                       WHERE c.relowner = u.usesysid AND c.relkind = 'r'
                       AND not exists (select 1 from pg_views where viewname = c.relname)
                       AND c.relname !~ '^(pg_|sql_)'
                       UNION
                       SELECT c.relname as "Name"
                       FROM pg_class c
                       WHERE c.relkind = 'r'
                       AND not exists (select 1 from pg_views where viewname = c.relname)
                       AND not exists (select 1 from pg_user where usesysid = c.relowner)
                       AND c.relname !~ '^pg_'"]
Pasting the above query in a shell works fine and lists all the tables. Here's my INI file: [DB_DataObject]
database        = pgsql://postgres:XXXXX@localhost/compendium2005
       ; the default database dsn see pear spec for more details
schema_location = XXX
       ;directory where the database ini files are..
class_location = XXX
       ; directory where the Table classes are..
require_prefix = DataObjects/
       ;  prefix for the 'require statement'
class_prefix    = DataObjects_
       ; Prefix Mapping of table name to PHP Class
;               the generator settings (optional)
extends_location =     ;               string added to php file for 'include('DB/DataObject');'
;               usefull if you want to add an extra layer - eg. a table level auth scheme..
;               optional    :: default = DB/DataObject.php
extends =          ;               string used in Table_XXX extends YYYY {
;               usefull if you want to add an extra layer - eg. a table level auth scheme..
;               optional    :: default = DB_DataObject
debug = 1
;               default debugging level
production = 0
;        this disables all debugging (so you cant set it run time), and should
;        improve performace
Any ideas? Jeroen

« previous php.pear.general (#17123) next »