On Fri, Nov 8, 2013 at 11:39 AM, George Silva <[email protected]>wrote:

> I only had to query external databases.
>
> I've created my models as managed=False and implemented a custom manager
> that redefined the default database configuration. We did not had
> situations where depending on a certain condition the target database would
> change, but this worked just fine.
>

What database configuration did you change ?

Regards,

>
>
> On Fri, Nov 8, 2013 at 12:45 PM, Ovnicraft <[email protected]> wrote:
>
>> Hi to all friends !
>>
>> I am working in django project its has many apps with their default db
>> configured.
>> So now i need to read (and possible write) to third DB (mysql) and i
>> found a thread[1] here about it.
>>
>> There are some suggestions about write ReadOnly objects, redefine save
>> methods but i'm not totally convinced about it.
>>
>> Reading documentation about multidb i found DB routes and it has
>> allow_syndb[2] so my question is, if i code to dont allow sync any model in
>> third db i can query (RAW SQL) without problems ?
>>
>> I dont want to write any dirty layer to connect to my third DB just
>> re-use django engine.
>>
>> I will appreciated your help !
>>
>> Best regards,
>>
>> [1]
>> https://groups.google.com/forum/#!msg/django-users/rv6D5Pqs7Fo/pkwinU7PGOQJ
>> [2]
>> https://docs.djangoproject.com/en/1.4/topics/db/multi-db/#allow_syncdb
>>
>>
>> --
>> Cristian Salamea
>> @ovnicraft
>>
>> --
>> You received this message because you are subscribed to the Google Groups
>> "Django users" 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/django-users.
>> To view this discussion on the web visit
>> https://groups.google.com/d/msgid/django-users/CA%2B16coM5s7KgGrMF4MqTGY5DYZ%2B7M43-4PkV14sm2yNTvstCHA%40mail.gmail.com
>> .
>> For more options, visit https://groups.google.com/groups/opt_out.
>>
>
>
>
> --
> George R. C. Silva
> SIGMA Consultoria
> ----------------------------
> http://www.consultoriasigma.com.br/
>
> --
> You received this message because you are subscribed to the Google Groups
> "Django users" 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/django-users.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/django-users/CAGyPVTsLt%2BPcWojAeGJFGqE9oNsR4HA6ecgnYg8zeBU%2BTGFG-g%40mail.gmail.com
> .
> For more options, visit https://groups.google.com/groups/opt_out.
>



-- 
Cristian Salamea
@ovnicraft

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" 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/django-users.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/CA%2B16coOOX0W6MjxDvB9GRUjq%3D-tYj4bfZX%2B_K1hV1rUt-uMpiA%40mail.gmail.com.
For more options, visit https://groups.google.com/groups/opt_out.

Reply via email to