[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
SF.net SVN: ledger-smb:[5727] trunk/sql
- Subject: SF.net SVN: ledger-smb:[5727] trunk/sql
- From: ..hidden..
- Date: Tue, 30 Apr 2013 11:05:16 +0000
Revision: 5727
http://sourceforge.net/p/ledger-smb/code/5727
Author: einhverfr
Date: 2013-04-30 11:05:15 +0000 (Tue, 30 Apr 2013)
Log Message:
-----------
Correcting load issues with the database
Modified Paths:
--------------
trunk/sql/Pg-database.sql
trunk/sql/modules/Roles.sql
Modified: trunk/sql/Pg-database.sql
===================================================================
--- trunk/sql/Pg-database.sql 2013-04-30 08:04:38 UTC (rev 5726)
+++ trunk/sql/Pg-database.sql 2013-04-30 11:05:15 UTC (rev 5727)
@@ -2220,7 +2220,7 @@
$$ This table sets the basic preferences for formats, languages, printers, and user-selected stylesheets.$$;
CREATE TABLE recurring (
- id int references journal_entry(id),
+ id int references journal_entry(id) unique,
reference text,
startdate date,
nextdate date,
Modified: trunk/sql/modules/Roles.sql
===================================================================
--- trunk/sql/modules/Roles.sql 2013-04-30 08:04:38 UTC (rev 5726)
+++ trunk/sql/modules/Roles.sql 2013-04-30 11:05:15 UTC (rev 5727)
@@ -1630,6 +1630,8 @@
IF TG_OP = 'DELETE' THEN
RETURN OLD;
ELSE
+ IF pg_has_role('postgres', 'USAGE') THEN RETURN NEW -- is superuser
+ END IF;
SELECT * INTO r_eclass from entity_class WHERE id = NEW.entity_class;
IF pg_has_role(SESSION_USER,
lsmb__role('contact_class_'
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.