Django manage.py can provide direct access to your models.
python manage.py shell
is your friend, for manually manipulating data, including the database via the Django ORM.
This link to the Django docs could provide a good starting point, particularly further down the page where models are queried using the Django shell.
Secondly are the import and export data commands available in manage.py, in particular the dumpdata and loaddata commands. I suspect this is what you are looking for.
On 29 Oct 2020, at 05:33, Kiran Bangde <kiranb0218@gmail.com> wrote:
Hi everyone,
Iam stuck at a point ...I want to fetch a data from a database , where data should be insert manually , plz help me how to do that how to fire a queries in DB and how to use primary key and foreign key over here.Please help me ,Iam new to Django .
Thanks in advance--
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+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/django-users/CAH3w0pg60HpYHzta5hjHTw7NaiBbuh7Q1uOfG%2BkZnRAGgQLOYA%40mail.gmail.com.
No comments:
Post a Comment