In the project, every year new books are opened and every organization
has it's own database for ever every financial year.
Happy hacking.
Krishnakant.
On Tuesday 13 October 2015 07:49 AM, Tim Graham wrote:
You can execute management commands from Python code using call_command():
https://docs.djangoproject.com/en/stable/ref/django-admin/#running-management-commands-from-your-code
It seems a bit risky to me to expose functionality to your users that
allow them to change your database schema as a result of some action.
This isn't really how Django is designed in terms of having models
which map to database tables, but I suppose there could be use cases
for doing that. I'll be curious to learn if others have done anything
like you propose.
On Sunday, October 11, 2015 at 11:15:30 PM UTC-7, krmane wrote:
Hello all.
The financial project I am developing requires that when the user
creats
on create organization. the Migrate command has to be run
automatically.
I have 2 questions regarding this.
1, If I am using sqlalchemy instead of sqlobject, will the migrate
utility work?
2, If yes then how can I do this through code in a view function?
if no
then is there a way to do it through sqlalchemy? or should I use the
create_all function in sqlalchemy itself?
Happy hacking.
Krishnakant.
--
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 django-users+unsubscr...@googlegroups.com
<mailto:django-users+unsubscr...@googlegroups.com>.
To post to this group, send email to django-users@googlegroups.com
<mailto:django-users@googlegroups.com>.
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/309f6eba-6f93-4e5e-a23e-42073e8e9c77%40googlegroups.com
<https://groups.google.com/d/msgid/django-users/309f6eba-6f93-4e5e-a23e-42073e8e9c77%40googlegroups.com?utm_medium=email&utm_source=footer>.
For more options, visit https://groups.google.com/d/optout.
--
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 django-users+unsubscr...@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
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/561C6BEC.7060704%40gmail.com.
For more options, visit https://groups.google.com/d/optout.