db = DAL('postgres://usuario:puerto@localhost:5432/welcome', pool_size=1,check_reserved=['all'], fake_migrate_all=True)
db.define_table('denuncia', Field('status', 'integer', default=0, writable=False, readable=False), Field('descripcion', 'text'), Field('ip', 'string', default=request.client, update=request.client, writable=False, readable=False), Field('fecha', 'date', default=request.now, update=request.now, writable=False, readable=False), Field('victima', db.auth_user, default=auth_user_id, writable=False, readable=False), Field('auth_user', db.auth_user, writable=False, readable=False), #format = lambda row: '%s %s' %(row.auth_user.username) ) #requires db.denuncia.descripcion.requires = [ IS_UPPER(), IS_LENGTH(maxsize=256, minsize=20), IS_NOT_EMPTY(), ] timestamp: 2014-02-05T04:21:31.624321 CREATE TABLE denuncia( id SERIAL PRIMARY KEY, status INTEGER, descripcion TEXT, ip VARCHAR(512), fecha DATE, victima INTEGER REFERENCES auth_user (id) ON DELETE CASCADE, auth_user INTEGER REFERENCES auth_user (id) ON DELETE CASCADE ); faked! web2py™Version 2.8.2-stable+timestamp.2013.11.28.13.54.07 PythonPython 2.6.6: /usr/bin/python (prefix: /usr) Traceback Traceback (most recent call last): File "/home/www-data/web2py/gluon/restricted.py", line 217, in restricted exec ccode in environment File "/home/www-data/web2py/applications/welcome/controllers/denuncia.py", line 95, in <module> File "/home/www-data/web2py/gluon/globals.py", line 372, in <lambda> self._caller = lambda f: f() File "/home/www-data/web2py/gluon/tools.py", line 3239, in f return action(*a, **b) File "/home/www-data/web2py/applications/welcome/controllers/denuncia.py", line 67, in admin denuncia_rows = db(db.denuncia.auth_user>0)(db.auth_user.id ==db.denuncia.auth_user)(db.auth_user.registration_key!='blocked').select(db.denuncia.ALL) File "/home/www-data/web2py/gluon/dal.py", line 10335, in select return adapter.select(self.query,fields,attributes) File "/home/www-data/web2py/gluon/dal.py", line 1831, in select return self._select_aux(sql,fields,attributes) File "/home/www-data/web2py/gluon/dal.py", line 1796, in _select_aux self.execute(sql) File "/home/www-data/web2py/gluon/dal.py", line 1916, in execute return self.log_execute(*a, **b) File "/home/www-data/web2py/gluon/dal.py", line 1910, in log_execute ret = self.cursor.execute(command, *a[1:], **b) ProgrammingError: permiso denegado a la relación denuncia Error snapshot <class 'psycopg2.ProgrammingError'>(permiso denegado a la relación denuncia )-- http://diazluis.com Analista Programador User Linux 532223 -- Resources: - http://web2py.com - http://web2py.com/book (Documentation) - http://github.com/web2py/web2py (Source code) - https://code.google.com/p/web2py/issues/list (Report Issues) --- You received this message because you are subscribed to the Google Groups "web2py-users" group. To unsubscribe from this group and stop receiving emails from it, send an email to web2py+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/groups/opt_out.