[Rails] Re: help finding database items that lost parent item

2010-04-26 Thread Marnen Laibow-Koser
Scott Kulik wrote: [...] >> Then please spend some quality time with an SQL reference. If you can't >> write simple joins, then you are not yet ready to develop Web >> applications that use SQL databases. >> >> Best, >> -- >> Marnen Laibow-Koser >> http://www.marnen.org >> mar...@marnen.org >

[Rails] Re: help finding database items that lost parent item

2010-04-26 Thread Scott Kulik
Marnen Laibow-Koser wrote: > Scott Kulik wrote: >> Frederick Cheung wrote: >>> On Apr 25, 1:57�am, Scott Kulik wrote: updating the database when a users has problems with their private messages page. I'm wondering if someone knows a good way I could scan the the pm's table

[Rails] Re: help finding database items that lost parent item

2010-04-26 Thread Marnen Laibow-Koser
Scott Kulik wrote: > Frederick Cheung wrote: >> On Apr 25, 1:57�am, Scott Kulik wrote: >>> updating the database when a users has problems with their private >>> messages page. >>> >>> I'm wondering if someone knows a good way I could scan the the pm's >>> table and delete messages that no longer

[Rails] Re: help finding database items that lost parent item

2010-04-25 Thread Frederick Cheung
On Apr 25, 6:35 pm, Scott Kulik wrote: > Frederick Cheung wrote: > > On Apr 25, 1:57 am, Scott Kulik wrote: > >> updating the database when a users has problems with their private > >> messages page. > > >> I'm wondering if someone knows a good way I could scan the the pm's > >> table and delet

[Rails] Re: help finding database items that lost parent item

2010-04-25 Thread Scott Kulik
Frederick Cheung wrote: > On Apr 25, 1:57�am, Scott Kulik wrote: >> updating the database when a users has problems with their private >> messages page. >> >> I'm wondering if someone knows a good way I could scan the the pm's >> table and delete messages that no longer have a user for sent_to or

[Rails] Re: help finding database items that lost parent item

2010-04-25 Thread Frederick Cheung
On Apr 25, 1:57 am, Scott Kulik wrote: > I have a table for private messages similar to: > > PMS: > title > body > sent_to (foreign key to users table) > sent_from (foreign key to users table) > > When I originally set it up I didn't have it automatically a users pm's > when that user was delete