Hi,

The content of the context dict can be anything, including of course values 
read from the database thanks to the sqlite3 lib. What Django generic views 
working with templates do is transfering for you the object field values to 
context entries and also automating the creation of form fields based on the 
model introspection.


WRT to you question about the size of the data, it depends on what you want to 
do. If you plan to display thousands of records in a single HTML page, it will 
not very efficient for sure and the browser may choke in extreme situations. To 
work around this, you can either implement pagination by yourself, using f.i. 
AJAX requests to return chunks of data as JSON packets and process them by a 
bit of Javascript on the client side to update your page. You can also look for 
JS widgets implementing this for you. I remember having used Datatables 
(https://datatables.net/) a while ago, and it does its job pretty well.

DataTables Table plug-in for jQuery<https://datatables.net/>
datatables.net
Create customised, editable tables in minutes with Editor for DataTables. Save 
your time writing yet another CRUD application - Editor is a premium extension 
created to produce complex, fully editable tables that take full advantage of 
all of the features of DataTables.

Regards


Eric

________________________________
From: django-users@googlegroups.com <django-users@googlegroups.com> on behalf 
of Sourabh Jaiswal <sourabhjaiswa...@gmail.com>
Sent: Thursday, May 24, 2018 8:22:17 AM
To: Django users
Subject: Re: Open Sqlite database file directly in django

Hi,

Thanks a Lot for your reply.

Using standard python lib you are saying that I should send the data from view 
to template render using context dictionary.. right?

But in my case data can be huge... Is that a good way to do it?

Regards,
Sourabh Jaiswal.

On Tuesday, May 22, 2018 at 5:55:32 PM UTC+5:30, Sourabh Jaiswal wrote:
Hi,

Is there any way to open sqlite db directly in django.

I am working on an application for which a back end script creates a database 
for every execution.
The database consists of multiple tables and I have to show those tables on the 
web site made in django.

Is there any other way around for this?

Any help will be greatly appreciated.

Thanks,
Jaiswal.

--
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 https://groups.google.com/group/django-users.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/e15842ab-861f-4b28-ac92-a1109e61be95%40googlegroups.com<https://groups.google.com/d/msgid/django-users/e15842ab-861f-4b28-ac92-a1109e61be95%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 https://groups.google.com/group/django-users.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/DB7P193MB0331F3FF8D9BA571A59F9DDE8C6A0%40DB7P193MB0331.EURP193.PROD.OUTLOOK.COM.
For more options, visit https://groups.google.com/d/optout.

Reply via email to