On Tue, May 21, 2013 at 2:16 PM, Simon Riggs <si...@2ndquadrant.com> wrote:
> On 21 May 2013 13:04, Tom Evans <tevans...@googlemail.com> wrote:
>> On Sun, May 19, 2013 at 11:51 PM, Scott Anderson
>> <scottanderso...@gmail.com> wrote:
>>> On Sunday, May 19, 2013 11:18:07 AM UTC-4, WongoBongo wrote:
>>>>
>>>> You don't have to become an expert with postgres to use Django. You can do
>>>> most of the db development using SQLite and hold off on postgres until you
>>>> are ready to deploy.
>>>
>>>
>>>
>>> I highly recommend *against* waiting for PostgreSQL until deployment. There
>>> are significant differences between SQLite, PostgreSQL, and MySQL. If you
>>> wait until deployment to test on your production database you will find
>>> yourself fixing and changing things at the last minute. Start testing on
>>> your production deployment database as soon as possible.
>>
>> The purpose of using an ORM is to make your application database
>> agnostic.
>
> ORM stands for Object Relational Mapper. My thinking is that if its
> role was solely to make applications database agnostic it would be
> called something like Common Database Interface, or Database Agnostic
> Layer. Such things do exist, yet so do ORMs. ISTM that ORMs help you
> write good applications, not just make things agnostic.

Opinions. We've all got them. Django's one line description of their ORM:

  Django provides an abstraction layer (the “models”) for structuring
and manipulating the data of your Web application.

Django's abstraction layer provides a bunch of features, all of which
operate identically across a variety of database servers. Its an
abstraction layer that provides database agnostic features.

ISTM you're being overly pedantic.

>
>> You should not find that changing DB engine is overly
>> taxing.
>
> Hmm, well. A YMMV moment if ever there was one.

This comment was directed at the OP. The OP is just starting to use
any web development package, anything he does in Django with sqlite
should be easily switched to another database. Do you have some
examples of Django features he would find difficulty with if he
switched from using django/sqlite to django/postgres?

I know you do a lot of Postgresql consulting, I expect some of this
may involve migrating MySQL -> Postgres, and if you have an
application written for MySQL, it will be tricky porting it over.
However, this is not that scenario.

The only queries you need to rewrite on moving django/sqlite ->
django/postgres are raw queries. How many will this beginner have?
Should rewriting raw queries be the thing this beginner worries about?

'YMMV' indeed. Switching or changing DB engines in a Django app is not
hard, unless the app is extremely badly written.

>
>> The point is, installing and learning the ins and outs of an RDBMS is
>> not necessary to using Django.
>
> Often, yes. But mostly, one needs to consider details about the whole
> stack in making things work well.
>
> There are lots of good reasons for careful selection of each part of
> your stack. Choosing Django was no doubt an informed decision and one
> made with a view to the many good things this gives you. Other
> products in your stack benefit from similar careful and informed
> decision making.
>
> Otherwise we'd all be using microCOBOL on Netware.

Yes. I'm sure the OP is also making a pro/con list to decide which of
gunicorn and Tornado to use.

>
>> If you think you are stuck trying to
>> install or understand postgres, just ignore it and use sqlite. You can
>> always change at a later date.
>
> Changing a major architectural component in your stack is not a
> trivial thing. Major changes affect the quality of your deliverables.

The most important thing as a beginner developer is to start
developing things, and don't get distracted by irrelevancy. Messing
about getting the perfect Postgresql install will not get you any
further with being able to develop websites in Django, and seeing as
that is what the OP wanted to do, if postgresql is a problem for him,
he should ignore it, and start the work he wanted to do.

You do not need postgresql to develop in Django, just like you don't
need Apache/mod_wsgi. The simplest, easiest and most straightforward
way is to use sqlite as your database, and to serve pages using
runserver.

-- 
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?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.


Reply via email to