In the Model you can specify the name of the table that it should use:
var $useTable = 'tablename';
On Aug 26, 2:54 pm, JuanWalker <[email protected]> wrote:
> I'm tryinig to access a modem that I can't change the name through
> another model ( belongsto association) the problem is that this table
> was not created using plurar form so I have problems when I try to
> access it.
>
> UseTable it's not working on this, please helpme.
>
> Here's the code :
>
> class MdlAssignment extends AppModel{
>
> var $name = "MdlAssignment";
> var $belongsTo = "AssignmentsGroup";
> var $hasmany = "MdlAssignmentSubmission";
>
> }
>
> On browser appears :
> Database table mld_assignments for model MldAssignment was not found.
>
> The table is called mld_assignment and as I say I can't rename this
> table. Thanks for answer me
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"CakePHP" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/cake-php?hl=en
-~----------~----~----~----~------~----~------~--~---