Comments for Experimental Thoughts http://thoughts.davisjeff.com Ideas on Databases, Logic, and Language by Jeff Davis Tue, 19 Jun 2012 16:18:51 +0000 hourly 1 http://wordpress.org/?v=3.3.1 Comment on Applications vs. Platforms by Kwabena Aning http://thoughts.davisjeff.com/2012/06/16/applications-vs-platforms/comment-page-1/#comment-2547 Kwabena Aning Tue, 19 Jun 2012 16:18:51 +0000 http://thoughts.davisjeff.com/?p=565#comment-2547 I find this very interesting as I am investigating architectures and the semantic web myself. I find that when you have very little visibility over or care for the language an application is built on and you are generally considering the architecture of the software you may want to start thinking of it as a platform. That notwithstanding, I find that you reduced this down to what one might define as a platform although you are looking at it from a "developer" end user perspective, one may also want to consider it from a "machine" end user perspective where another device be it abstractly composed or developed by someone may consume the end product of the software. This forms a very good basis for defining the scope of what you may consider a platform. Thanks for sharing this. I find this very interesting as I am investigating architectures and the semantic web myself. I find that when you have very little visibility over or care for the language an application is built on and you are generally considering the architecture of the software you may want to start thinking of it as a platform. That notwithstanding, I find that you reduced this down to what one might define as a platform although you are looking at it from a “developer” end user perspective, one may also want to consider it from a “machine” end user perspective where another device be it abstractly composed or developed by someone may consume the end product of the software.

This forms a very good basis for defining the scope of what you may consider a platform. Thanks for sharing this.

]]>
Comment on Taking a step back from ORMs by Tony Marston http://thoughts.davisjeff.com/2012/02/26/taking-a-step-back-from-orms/comment-page-1/#comment-2476 Tony Marston Tue, 06 Mar 2012 10:23:04 +0000 http://thoughts.davisjeff.com/?p=498#comment-2476 In my entire career as a database and application designer I have only come across a single instance where I had something resembling inheritance in the data model. When implementing the PARTY database from Len Silverston's Data Model Resource Book I had the ORGANISATION table and the PERSON table both of which inherit from the PARTY table. Although the DBMS does not natively support inheritance it was a simple matter to do this in the code. It is a simple matter of putting the right code in the right place. What do you mean by "associations"? If you mean the association entity in a many-to-many relationship then again this is a simple matter of generating the right SQL query in the right place. Once I know what SQL query I need to solve my problem then as far as I am concerned the problem is solved. In my entire career as a database and application designer I have only come across a single instance where I had something resembling inheritance in the data model. When implementing the PARTY database from Len Silverston’s Data Model Resource Book I had the ORGANISATION table and the PERSON table both of which inherit from the PARTY table. Although the DBMS does not natively support inheritance it was a simple matter to do this in the code. It is a simple matter of putting the right code in the right place.

What do you mean by “associations”? If you mean the association entity in a many-to-many relationship then again this is a simple matter of generating the right SQL query in the right place. Once I know what SQL query I need to solve my problem then as far as I am concerned the problem is solved.

]]>
Comment on Taking a step back from ORMs by Tony Marston http://thoughts.davisjeff.com/2012/02/26/taking-a-step-back-from-orms/comment-page-1/#comment-2475 Tony Marston Tue, 06 Mar 2012 10:14:25 +0000 http://thoughts.davisjeff.com/?p=498#comment-2475 Here is the link: http://thoughts.davisjeff.com/2012/02/26/taking-a-step-back-from-orms/comment-page-1/#comment-2440 Here is the link:

http://thoughts.davisjeff.com/2012/02/26/taking-a-step-back-from-orms/comment-page-1/#comment-2440

]]>
Comment on Taking a step back from ORMs by Mr President http://thoughts.davisjeff.com/2012/02/26/taking-a-step-back-from-orms/comment-page-1/#comment-2471 Mr President Tue, 06 Mar 2012 06:27:45 +0000 http://thoughts.davisjeff.com/?p=498#comment-2471 @Tony Marston, The way I see it, you recommend carrying out data modelling and using the data model as the object model. This is one way of implementing the data access layer. Your solution works on the thought process that OO model is unnecessary. If that is the case, need for ORM ceases to exist. The question that remains is what if you need to model OO paradigm like inheritance, associations etc? Is that possible in your approach? @Tony Marston,

The way I see it, you recommend carrying out data modelling and using the data model as the object model. This is one way of implementing the data access layer. Your solution works on the thought process that OO model is unnecessary. If that is the case, need for ORM ceases to exist. The question that remains is what if you need to model OO paradigm like inheritance, associations etc? Is that possible in your approach?

]]>
Comment on Taking a step back from ORMs by Mr President http://thoughts.davisjeff.com/2012/02/26/taking-a-step-back-from-orms/comment-page-1/#comment-2461 Mr President Mon, 05 Mar 2012 06:19:05 +0000 http://thoughts.davisjeff.com/?p=498#comment-2461 @Tony Marston, I would appreciate if you could provide a link to your said post. @Tony Marston,

I would appreciate if you could provide a link to your said post.

]]>
Comment on Taking a step back from ORMs by umlcat http://thoughts.davisjeff.com/2012/02/26/taking-a-step-back-from-orms/comment-page-1/#comment-2455 umlcat Sun, 04 Mar 2012 23:24:22 +0000 http://thoughts.davisjeff.com/?p=498#comment-2455 As you may know, first PHP database libraries use something like the myRecord["MyField"], kind of hash syntax. Delphi use something like myRecord("MyField"). A mix of both KeyValue ("hash"), and Property may also be used. As you may know, first PHP database libraries use something like the myRecord["MyField"], kind of hash syntax. Delphi use something like myRecord(“MyField”).

A mix of both KeyValue (“hash”), and Property may also be used.

]]>
Comment on Taking a step back from ORMs by Tony Marston http://thoughts.davisjeff.com/2012/02/26/taking-a-step-back-from-orms/comment-page-1/#comment-2452 Tony Marston Sun, 04 Mar 2012 10:14:01 +0000 http://thoughts.davisjeff.com/?p=498#comment-2452 @ nully > ORM is designed to simplify complex relationship of RDBMS. Are you implying that you can only handle complex relationships with an ORM? If so you are sadly mistaken. I have an ERP application with over 200 tables and 350 relationships and *NO* ORM.If I can do it then anybody can. @ nully

> ORM is designed to simplify complex relationship of RDBMS.

Are you implying that you can only handle complex relationships with an ORM? If so you are sadly mistaken. I have an ERP application with over 200 tables and 350 relationships and *NO* ORM.If I can do it then anybody can.

]]>
Comment on Taking a step back from ORMs by Tony Marston http://thoughts.davisjeff.com/2012/02/26/taking-a-step-back-from-orms/comment-page-1/#comment-2448 Tony Marston Sat, 03 Mar 2012 15:33:04 +0000 http://thoughts.davisjeff.com/?p=498#comment-2448 @ Mr President > The object and relational world represent two different > paradigms. Both should be developed independently to > utilize their individual paradigm specific best practices. It is possible to employ sound Object Oriented techniques in your application code *AND* keep synchronised with the relational structure *WITHOUT* using a second Object Oriented Design which produces a conflicting and mismatched structure. See my post dated March 2, 2012 at 03:41 which describes how I deliberately avoid the OOD step as it is totally redundant. This enables me to produce an application which does *NOT* have any mismatch between my Object and Relational structures, therefore I do not need to pollute my code with that abomination called an ORM. As for “best practices” there are too many developers who have totally different ideas on what “best” really means, so I will stick with what works for me. @ Mr President

> The object and relational world represent two different
> paradigms. Both should be developed independently to
> utilize their individual paradigm specific best practices.

It is possible to employ sound Object Oriented techniques in your application code *AND* keep synchronised with the relational structure *WITHOUT* using a second Object Oriented Design which produces a conflicting and mismatched structure. See my post dated March 2, 2012 at 03:41 which describes how I deliberately avoid the OOD step as it is totally redundant. This enables me to produce an application which does *NOT* have any mismatch between my Object and Relational structures, therefore I do not need to pollute my code with that abomination called an ORM. As for “best practices” there are too many developers who have totally different ideas on what “best” really means, so I will stick with what works for me.

]]>
Comment on Taking a step back from ORMs by Tony Marston http://thoughts.davisjeff.com/2012/02/26/taking-a-step-back-from-orms/comment-page-1/#comment-2447 Tony Marston Sat, 03 Mar 2012 15:25:26 +0000 http://thoughts.davisjeff.com/?p=498#comment-2447 @ Mr President > In some comments it was mentioned that the object model and > relational model have a 1-to-1 relationship. If such is the case > either the application is too simplistic or the models are > inappropriate and need to be revisited. I disagree completely. I have used the one-class-per-table approach for years. I don't use an ORM to generate my boilerplate SQL queries, instead I use intelligent Data Access Objects (see my post dated March 2, 2012 at 03:41). I have built an entire ERP application using this methodology containing over 200 tables, 350 relationships and 1700 transactions, so in no way could it be called "too simplistic" or "inappropriate". @ Mr President

> In some comments it was mentioned that the object model and
> relational model have a 1-to-1 relationship. If such is the case
> either the application is too simplistic or the models are
> inappropriate and need to be revisited.

I disagree completely. I have used the one-class-per-table approach for years. I don’t use an ORM to generate my boilerplate SQL queries, instead I use intelligent Data Access Objects (see my post dated March 2, 2012 at 03:41). I have built an entire ERP application using this methodology containing over 200 tables, 350 relationships and 1700 transactions, so in no way could it be called “too simplistic” or “inappropriate”.

]]>
Comment on Taking a step back from ORMs by Tony Marston http://thoughts.davisjeff.com/2012/02/26/taking-a-step-back-from-orms/comment-page-1/#comment-2446 Tony Marston Sat, 03 Mar 2012 15:15:35 +0000 http://thoughts.davisjeff.com/?p=498#comment-2446 @ nully > I won’t consider using an ORM if I only have a few tables of a > few columns. On the other hand, if I have hundreds of tables > and hundreds of fields, maintaining the SQL scripts for all the > queries I need is a laborious task. If you are still writing individual queries in your code then you are doing something seriously wrong. See my post dated March 2, 2012 at 03:41 where I describe how I use a single Data Access Object to generate every type of query for every database in my application. This means that the number of tables in my application, or the number of columns in an individual table is irrelevant. My largest application has over 200 tables, 350 relationships, 1700 transactions and *NO* ORM, and has been serving an internet business for nearly 4 years, so don't tell me it can't be done. @ nully

> I won’t consider using an ORM if I only have a few tables of a
> few columns. On the other hand, if I have hundreds of tables
> and hundreds of fields, maintaining the SQL scripts for all the
> queries I need is a laborious task.

If you are still writing individual queries in your code then you are doing something seriously wrong. See my post dated March 2, 2012 at 03:41 where I describe how I use a single Data Access Object to generate every type of query for every database in my application. This means that the number of tables in my application, or the number of columns in an individual table is irrelevant. My largest application has over 200 tables, 350 relationships, 1700 transactions and *NO* ORM, and has been serving an internet business for nearly 4 years, so don’t tell me it can’t be done.

]]>