Thanks Javier and what about ID (PK) fields? Need to be specified too or
Rails is smart enough to get them from tables?

Ing. Reynier Perez Mira
eMail: reynie...@gmail.com, reynie...@hotmail.com
Skype: reynierpm
Mobile: +58 424.180.5609
Site: http://reynierpm.site90.com


On Fri, Mar 2, 2012 at 11:06 AM, Javier Quarite <jquari...@gmail.com> wrote:

>
>
> On Fri, Mar 2, 2012 at 10:33 AM, reynie...@gmail.com 
> <reynie...@gmail.com>wrote:
>
>> Hi:
>> I'm starting a simple application to learn Rails and Ruby of course. I
>> come from PHP and frameworks like Symfony, CakePHP and CodeIgniter and some
>> of them have a task to create DB models from existent database which is my
>> case. I have a PostgreSQL database which want to use in my app. My question
>> is: exists any rake or rails command to generate models if they exists in
>> Rails?
>>
>> Ing. Reynier Perez Mira
>> eMail: reynie...@gmail.com, reynie...@hotmail.com
>> Skype: reynierpm
>> Mobile: +58 424.180.5609
>> Site: http://reynierpm.site90.com
>>
>
>
> A model can be generated using
>
> rails generate model MODELNAME  field1:type field2:type .....
>
>
>
> Javier Q.
>
>  --
> You received this message because you are subscribed to the Google Groups
> "Ruby on Rails: Talk" group.
> To post to this group, send email to rubyonrails-talk@googlegroups.com.
> To unsubscribe from this group, send email to
> rubyonrails-talk+unsubscr...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/rubyonrails-talk?hl=en.
>

-- 
You received this message because you are subscribed to the Google Groups "Ruby 
on Rails: Talk" group.
To post to this group, send email to rubyonrails-talk@googlegroups.com.
To unsubscribe from this group, send email to 
rubyonrails-talk+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/rubyonrails-talk?hl=en.

Reply via email to