You're right, db selects do not appear to be working in the web-based 
shell, at least not on Windows using SQLite. Are you sure it used to work 
(specifically on Windows) -- I haven't tried it in a while, but I seem to 
recall having problems with this a long time ago? I always use a standard 
OS shell instead.

Anthony

On Thursday, March 15, 2012 3:14:56 PM UTC-4, Stefan Scholl wrote:
>
> Sorry, my "bug report" was a bit short. Was called to a meeting 5
> minutes earlier than planned.
>
> I tested this with the example app because I wanted a clear test
> case. The bug was first seen in a bigger applicationi(, where I
> wanted to see why the common_filter feature only worked in the
> database admin interface and not in simple queries inside the
> app.)
>
>
> Person and dog inserted via database admin. After that the shell
> from the admin interface was used. The variable dogs was
> undefined after that. And no output with just
> "db().select(db.dog.ALL)".
>
>
> This isn't the case with older versions. I don't know which
> version first had this bug. Maybe I'm the only one using this
> interactive shell on the web interface.
> Somewhere between 1.91.x and 1.99.7
>
>
> Anthony <abasta...@gmail.com> wrote:
> > 
> > Did you do the insert in the shell also? If so, when you do inserts, 
> > updates, deletes in the shell, you have to follow with db.commit() in 
> order 
> > to commit the transaction. This is not necessary in application code 
> > because the framework does that automatically at the end of a request. I 
> > have also found that in some cases, the web-based shell in admin does 
> not 
> > work for database transactions, so you may need to use a regular OS 
> shell.
> > 
> > Anthony
> > 
> > On Thursday, March 15, 2012 4:12:10 AM UTC-4, Stefan Scholl wrote:
> >>
> >> web2py 1.99.7 for Windows.
> >>
> >> Example app, inserted 1 person and 1 dog.
> >>
> >> In the shell:
> >>
> >>         dogs = db().select(db.dog.ALL)
> >>
> >>
> >> Nothing there. And "dogs" isn't defined.
> >>
> >>
>
>
> -- 
> Web (en): http://www.no-spoon.de/ -*- Web (de): http://www.frell.de/
> <!--[if IE 6]><script>for(x in document.open);</script><![endif]-->
>
>

Reply via email to