Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.python > #38301
| From | Walter Hurry <walterhurry@lavabit.com> |
|---|---|
| Newsgroups | comp.lang.python |
| Subject | Re: Thoughts on SQL vs ORM |
| Date | 2013-02-06 20:03 +0000 |
| Organization | albasani.net |
| Message-ID | <keucur$qld$2@news.albasani.net> (permalink) |
| References | <mailman.1408.1360155567.2939.python-list@python.org> <bda93f4d-c27b-43a7-bfdc-3fbd77e41f56@u21g2000vbo.googlegroups.com> |
On Wed, 06 Feb 2013 10:03:08 -0800, rusi wrote: > On Feb 6, 5:58 pm, Andriy Kornatskyy <andriy.kornats...@live.com> wrote: >> The question of persistence implementation arise often. I found >> repository pattern very valuable due to separation of concerns, mediate >> between domain model and data source (mock, file, database, web >> service, etc). >> >> The database data source is somewhat specific since you can proceed >> with SQL functions or ORM. Here are some thoughts why you might prefer >> SQL functions over ORM in your next project: >> >> http://mindref.blogspot.com/2013/02/sql-vs-orm.html >> >> Comments or suggestions are welcome. >> >> Thanks. >> >> Andriy Kornatskyy > > Interesting read. Your first 2 points: > 1. It is not valid to think that relational model in database is domain > model of application. They are different (except some trivial cases). > 2. … Design your domain model with plain objects only > > And then later you go on to recommend SQL over ORM. So its not clear > which side you are on! > > My own very preliminary thoughts on this: > SQL is basically a functional language. > OOP is just imperative programming with some syntactic sugar, name- > spacing etc. > IOW OOP is a lower level paradigm than FP because it deals with the > 'how' more than the 'what.' > > Object-relational impedance mismatch happens because of the opposite > reason to what people seem to believe: Because the higher-level SQL is > pulled down into the lower-level OO mindset and not the other way around I'm afraid I don't understand what all that means. But I invariably go for SQL over any abstraction paradigm.
Back to comp.lang.python | Previous | Next — Previous in thread | Find similar | Unroll thread
Thoughts on SQL vs ORM Andriy Kornatskyy <andriy.kornatskyy@live.com> - 2013-02-06 15:58 +0300
Re: Thoughts on SQL vs ORM rusi <rustompmody@gmail.com> - 2013-02-06 10:03 -0800
Re: Thoughts on SQL vs ORM Walter Hurry <walterhurry@lavabit.com> - 2013-02-06 20:03 +0000
csiph-web