Hi,

I am trying to create a table which accepts log files.
One of the entries that should be unique is log path. No Duplicate entries.

db.define_table('logs_db',
                Field('case_num', requires=IS_NOT_EMPTY()),
                Field('case_desc',),
                Field('log_gen_time', writable=False, readable=False),
                Field('log_uniq_name', writable=False, readable=False, 
unique=True),
                Field('log_path', unique=True, requires=IS_NOT_EMPTY()),
                auth.signature)


I am now using the above format.
Even with unique=True  The form gets submitted.
I would have liked the form to be able to check if there is another entry 
for log_path, but it doesn't.
I have tried *primarykey=['log_path'] *as well, but to no affect.

I am using SQLite.


-- 
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/d/optout.

Reply via email to