so just a "read_me_only" kind of check where if you even try to load a 
record in an edit form web2py complains ?
or just complain before any insert(), update() is tried on any 
"read_me_only" fake table  (i.e. do those always in a try:except block or 
do before an "assert is_not_fake" before "write" operations)?

not sure cause I never had that requirement (and I don't have python right 
now), but wouldn't the same thing being accomplished by writable=False on 
all columns and using validate_and_update(), validate_and_insert() - as you 
should if you're unsure about the table model, i.e. you don't know if it's 
a table or a view ?
I'm a little unsure about the performance penalty on checking this kind of 
things every time when they can be prevented just knowing that that 
particular collection of entities is not writable ^_^

PS: some backends allow specially coded views to be updateable and 
deletable......




On Tuesday, April 30, 2013 5:35:09 PM UTC+2, Michele Comitini wrote:
>
>
>
>
> 2013/4/30 Niphlod <nip...@gmail.com <javascript:>>
>
>> put them on the roadmap ^_^ as for 3. it's just a matter of finding the 
>> right syntax for every db engine. I'm not sure about 4., it's available 
>> right now with migrate=False ?
>
>
> 4. migrate False is on the DDL side and you are right about that, but I'd 
> like it also on DML part i.e. in postgresql doing an INSERT on a VIEW is 
> not allowed.
>
>
>

-- 

--- 
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.


Reply via email to