From: Lane S. <la...@op...> - 2006-11-27 17:42:52
|
ok. I fixed it. here is the background. see http://archives.postgresql.org/pgsql-novice/2001-01/msg00290.php for changing the Owner of a table. here is the transcript of the sql: =# select usesysid from pg_user where usename = 'sql-ledger'; =# select usesysid from pg_user where usename = 'lane'; with the above integer values: =# update pg_class set relowner=101 where relowner=103; uniformly assigns the ID of sql-ledger to all of your tables. Lane Lane Sharman wrote: > List of relations > Schema | Name | Type | Owner >--------+----------------+----------+------------ > public | acc_trans | table | sql-ledger > public | ap | table | sql-ledger > public | ar | table | sql-ledger > public | assembly | table | sql-ledger > public | audittrail | table | lane > public | business | table | lane > > >shows that my ownership is partially corrupted. Normally, all datatbase >tables are owned by sql-ledger. So, I will change the owner to >sql-ledger? Please advise. > >thanks, Kasem. > >Lane > >Nefnifi, Kasem wrote: > > > >>Hi Lane, >> >>Logon into your db as DBA using pgadmin3 (use may be sql-ledger or >>postgres user), >>Grant permissions to the user lane. >>So the problem should be solved. >>Kasem, >> >> >>-----Original Message----- >>From: Lane Sharman [mailto:la...@op...] >>Sent: maandag 27 november 2006 5:35 >>To: sql...@sq... >>Subject: [SL] Corrupting Access >> >>I have corrupted access to my most important data set. Call it A. And >>call the user lane. >> >>Basically, in admin mode, I set up dataset B and saved the user as lane. >>That was a big mistake. Now I cannot get into dataset A under any >>user: >> >>DBD::Pg::st execute failed: ERROR: permission denied for relation >>customer at SL/Form.pm line 1823. >> >> >> Error! >> >>SELECT ct.name AS customer, a.curr AS currency, a.customer_id, >>current_date + ct.terms AS duedate, a.department_id, >>d.description AS department, ct.notes, ct.curr AS currency >> >> >>FROM ar a > > >>JOIN customer ct ON (a.customer_id = ct.id) >>LEFT JOIN department d ON (a.department_id = d.id) >>WHERE a.id = 10452 >>ERROR: permission denied for relation customerDatabase handle destroyed >>without explicit disconnect. >> >> >> >> >> > > > > -- Kindest Regards, Lane Sharman 858-755-2868 |