[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Language wars...



Ed W wrote:
>> I wasn't talking about the MVC model, I was talking about the ORM. The
>> ORM is the problem here not the MVC model :)
>>   
> 
> What do you perceive is the problem with an ORM in this instance?  Lets 
> assume for a moment that we disregard very simplistic solutions which 
> crudely map database rows to objects

We are moving to a 90% SP model. Meaning that all data logic is going to
happen in stored procedures. ORMs, at least every one that I have seen
have no easy way to deal with using SPs.

E.g; this will be an example create to create invoices:

SELECT create_invoice(customer_number,{line_item_array});
OR:

SELECT get_active_customers();

These are oversimple examples but ORMs that I know can not correctly
deal with that. You end up breaking out of the ORM api and writing
custom code.

So we immediately loose the advantage of the ORM.

Secondly ORMs are notorius for writing proper SQL but highly unoptimized
SQL. This is the nature of trying to be database independent which is a
flaw in design in general.

I don't feel like working around a piece of technology we don't need in
the first place :)

Sincerely,

Joshua D. Drake

-- 

      === The PostgreSQL Company: Command Prompt, Inc. ===
Sales/Support: +1.503.667.4564 || 24x7/Emergency: +1.800.492.2240
Providing the most comprehensive  PostgreSQL solutions since 1997
             http://www.commandprompt.com/

Donate to the PostgreSQL Project: http://www.postgresql.org/about/donate
PostgreSQL Replication: http://www.commandprompt.com/products/