Forum: Ruby on Rails Database is cached?

Announcement (2017-05-07): www.ruby-forum.com is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see rubyonrails.org/community and ruby-lang.org/en/community for other Rails- und Ruby-related community platforms.
1b93a10a12e060b8146b820e4e279cdb?d=identicon&s=25 pete (Guest)
on 2006-04-20 13:01
It appears that my database is cached.
If I have a simple action which displays all records in a table it works
fine, but if I then change one of the fields in the database using a
MySQL GUI it is not reflected when I press refresh in the browser. Even
if I clear the cache.
The actual view is not being cached anyway becasue if I add some text to
the view it is shown on refresh!

Is this normal or is something playing up?
Fb23bc8cd4030c526b0689276b34c8bd?d=identicon&s=25 Bryan Duxbury (bryanduxbury)
on 2006-04-20 14:42
pete wrote:
> It appears that my database is cached.
> If I have a simple action which displays all records in a table it works
> fine, but if I then change one of the fields in the database using a
> MySQL GUI it is not reflected when I press refresh in the browser. Even
> if I clear the cache.
> The actual view is not being cached anyway becasue if I add some text to
> the view it is shown on refresh!
>
> Is this normal or is something playing up?

Are you storing the item you're checking for updates in the session?
That would be a sure way to pull your hair out looking for changes when
you won't get any.
7cda78d70ab775710f6fa24e0a5b68db?d=identicon&s=25 Emin Hasanov (Guest)
on 2006-04-20 14:49
(Received via mailing list)
if you are not in development mode, you have to restart your web-server

also, I assume that your code is generic and should display all the
columns
3d333b0012928f3dd5a6861cb09ad683?d=identicon&s=25 Kris (Guest)
on 2006-04-20 18:08
No they are not in the session, its a direct database call, normal
scaffold.

"if you are not in development mode, you have to restart your
web-server"

I'm in development mode.

??
0158871402c1ecfa57952e8a379cfd10?d=identicon&s=25 Daniel Lucraft (Guest)
on 2006-04-20 18:28
Kris wrote:
> No they are not in the session, its a direct database call, normal
> scaffold.
>
> "if you are not in development mode, you have to restart your
> web-server"
>
> I'm in development mode.
>
> ??

I used MySQL Front for a while before realising that you have to press
the little green tick button to make sure the tables are updating after
edits. Anything like that?
3a81a52b809eb4458550fdab1e06c342?d=identicon&s=25 Guest (Guest)
on 2006-04-21 12:16
Daniel Lucraft wrote:
> Kris wrote:
>> No they are not in the session, its a direct database call, normal
>> scaffold.
>>
>> "if you are not in development mode, you have to restart your
>> web-server"
>>
>> I'm in development mode.
>>
>> ??
>
> I used MySQL Front for a while before realising that you have to press
> the little green tick button to make sure the tables are updating after
> edits. Anything like that?

I dont think so, I use SQLyog and have done for a while now.
Maybe I give it a few days and see if the problem goes...
Fb23bc8cd4030c526b0689276b34c8bd?d=identicon&s=25 Bryan Duxbury (bryanduxbury)
on 2006-04-21 16:09
So, are you changing the table structure (adding/renaming fields) and
then trying to see a difference in like a scaffold edit or new page?
Those fields are pulled out of the database when you generate your
scaffold, and they won't automatically update if you change your
underlying structure.
This topic is locked and can not be replied to.