Il giorno venerdì 6 marzo 2015 16:00:57 UTC+1, Pablo ha scritto:
>
> I'm not able to use this example, someone can give me a hint?
>
> <?php$foreignKeys = $sm->listTableForeignKeys('user');
>
> Now you can loop over the array inspecting each foreign key object:
>
> <?phpforeach ($foreignKeys as $foreignKey) {
> echo $foreignKey->getName() . ': ' . $foreignKey->getLocalTableName()
> ."\n";}
>
>
>
> error:
>
> <br />
> <b>Fatal error</b>: Call to a member function getName() on a non-object
> in
> <b>C:\xampp\htdocs\Zion\Lib\vendor\doctrine\dbal\lib\Doctrine\DBAL\Schema\ForeignKeyConstraint.php</b>
>
> on line <b>108</b><br />
>
Call to a member function getName() on a non-object
try write this inside foreach... one lood is on non-object $foreignKey (
this is the problem cant access to method getName())
var_dump($foreignKey);
--
You received this message because you are subscribed to the Google Groups
"doctrine-user" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/doctrine-user.
For more options, visit https://groups.google.com/d/optout.