Hi Is there a way to change the schema name in the annotation dynamically depending on environment? For example we have standard production env that uses different database names than test env, that prefixes all database names with _test. Using your proposed annotation would cause all tests to use production database names which we do not want to happen.
Thanks, Anais On Tuesday, 4 August 2015 21:51:01 UTC+1, Marco Pivetta wrote: > > Hi Nick, > > On 4 August 2015 at 22:38, Nick Doulgeridis <[email protected] > <javascript:>> wrote: > >> Hello, >> >> I am using Symfony2 and Doctrine and wondering if its possible to make >> cross db joins with Doctrine. >> In the past was using Propel and this was possible but have migrate to >> Doctrine and I would like to have this feature except it's supposed to be a >> bad practice. >> >> Thank a lot. >> >> -- >> > > You can have cross-db mapped entities by using mappings such as > @Table(schema="foo", name="bar") and then simply relying on DQL (it will > prefix the table name automatically when building the SQL strings). > > > Marco Pivetta > > http://twitter.com/Ocramius > > http://ocramius.github.com/ > > -- 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 https://groups.google.com/group/doctrine-user. For more options, visit https://groups.google.com/d/optout.
