You just need to read
doc: https://docs.djangoproject.com/en/1.10/topics/db/multi-db/
在 2017年1月31日星期二 UTC+13上午5:19:02,Chetan Gupta写道:
>
> Hi,
>
> I am new to django.
> My requirement is django application i have 3 db connection.
> I want 2 db connection is readonly.
>
> Please let me know how to
Hi,
I am new to django.
My requirement is django application i have 3 db connection.
I want 2 db connection is readonly.
Please let me know how to do that.
Regards
Chetan
--
You received this message because you are subscribed to the Google Groups
"Django users" group.
To unsubscribe from
Thanks Alex, that's great information, I shall dig in.
C
On Thursday, 25 February 2016 19:33:06 UTC, Alex wrote:
>
> Normally for a site you don't keep your db in version control because
> the table definitions come from Django. Now if you have data to
> prepopulate (each time you fresh clone)
Normally for a site you don't keep your db in version control because
the table definitions come from Django. Now if you have data to
prepopulate (each time you fresh clone) or need to do a backup then use
standard db backup mechanisms.
Like dumping your db to an sql backup. It's not efficient to
Well I don't, but I'm not sure what the alternatives are. I mean what I'm
interested in are *alternatives* to keeping it under version control, so I
have backups, history, versioning. Preferably something I can easily
integrate with my Django workflow, without having to manually keep external
Why do you want your db in version control at all? There is not normally a good
reason to do that.
--
DR.
--
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
I put my sqlite files into .gitignore.
Rafael E. Ferrero
2016-02-25 12:55 GMT-03:00 cortez :
> Hi,
>
> I'm using the out-of-the-box Sqlite database integration with my Django
> project, and I'm wondering how to manage it with respect to Git. Currently
> I have it
Hi,
I'm using the out-of-the-box Sqlite database integration with my Django
project, and I'm wondering how to manage it with respect to Git. Currently
I have it checked in, but I suspect this isn't what I want to be doing.
Also I have noticed that every time I log in to the admin interface and
Thanks a million Romain!!
It worked.
I thought about just naming it, but in the tutorial it said put the
path and I didnt want to mess up things.
Thanks again!!
Best
Z.
On May 11, 10:37 am, Romain Gaches wrote:
> Le 11 mai 2010 à 10:30, HelloWorld a écrit :
>
> > Hi
Le 11 mai 2010 à 10:30, HelloWorld a écrit :
> Hi Everybody
>
> I installed Django and wanted to test what I can do by using Sqlite.
> It is unclear for me how this can be achieved and therefore have the
> following open questions:
>
> 1. Do I need to fill in the settings.py any other info
Hi Everybody
I installed Django and wanted to test what I can do by using Sqlite.
It is unclear for me how this can be achieved and therefore have the
following open questions:
1. Do I need to fill in the settings.py any other info than:
django.db.backends.sqlite3 at ENGINE
What do I/ Do I need
Hi Guys,
My current setup for Django is as follows:
Ubuntu, with Lighttpd and running django via FCGI using TCP in
threaded mode. I a simple site, that uses SQLITE as the DB engine.
Though i have noticed that as the DB grows, the memory usage for that
particular process keeps increasing, is
On Mon, 2009-02-02 at 23:16 -0500, alexander lind wrote:
>
> On Feb 2, 2009, at 10:05 PM, Malcolm Tredinnick wrote:
> > > I always make my auto-inc fields primary as well, so no argument
> > > there.
> > > I tried using the AutoField when I noticed django didn't create
> > > the
> > >
On Feb 2, 2009, at 10:05 PM, Malcolm Tredinnick wrote:
>> I always make my auto-inc fields primary as well, so no argument
>> there.
>> I tried using the AutoField when I noticed django didn't create the
>> auto-incrementing fields correctly by itself in sqlite, but that
>> didn't work either
On Mon, 2009-02-02 at 09:42 -0500, alexander lind wrote:
> >>> Shows how infrequently AutoField's are really used in practice.
> >>> They're
> >>> generally just not that useful to specify.
> >>
> >>
> >> What else do people use for specifying autoinc fields?
> >
> > Auto-increment fields
>>> Shows how infrequently AutoField's are really used in practice.
>>> They're
>>> generally just not that useful to specify.
>>
>>
>> What else do people use for specifying autoinc fields?
>
> Auto-increment fields generally aren't that useful in practice,
> outside
> of primary keys (the
On Sat, 2009-01-31 at 16:56 -0500, alexander lind wrote:
>
> > >
> > > class User(models.Model):
> > > user_id = models.AutoField(primary_key=True)
> > >
> > > This produces a table in sqlite that will NOT take NULL for a
> > > value
> > > when inserting records. You get an error back.
> >
>> Anyway, if you you'd like to fix your patch to always do this for the
>> SQLite backend, that would be great (it looks like a one-line patch
>> to
>> django/db/backends/sqlite/creation.py).
>
> I don't see a simple way to make this happen. Doesn't seem like any
> other backend DB requires
>
>> Reading sqlites manual,
>> this is _supposed_ to work, but doesn't seem to. However and
>> furthermore, you don't really get autoincrement behavior from sqlite
>> unless you add in the SQL keyword "AUTOINCREMENT" when creating the
>> table.
>>
>> Django does not do this currently, so I
>>
>> class User(models.Model):
>> user_id =
>> models.AutoField(primary_key=True)
>>
>> This produces a table in sqlite that will NOT take NULL for a value
>> when inserting records. You get an error back.
>
> That's correct behaviour. A primary key
On Fri, 2009-01-30 at 22:37 -0500, alexander lind wrote:
> I am using the svn trunk version of Django.
>
> I was just starting a new django project using sqlite for the db
> backend. Excerpt from models.py:
>
> class User(models.Model):
> user_id =
I am using the svn trunk version of Django.
I was just starting a new django project using sqlite for the db
backend. Excerpt from models.py:
class User(models.Model):
user_id =
models.AutoField(primary_key=True)
This produces a table in sqlite
22 matches
Mail list logo