Click here to monitor SSC
SQLServerCentral is supported by Red Gate Software Ltd.
 
Log in  ::  Register  ::  Not logged in
 
 
 
        
Home       Members    Calendar    Who's On


Add to briefcase «««34567»»»

Where Logic Lives Expand / Collapse
Author
Message
Posted Tuesday, August 23, 2005 3:45 PM


Ten Centuries

Ten CenturiesTen CenturiesTen CenturiesTen CenturiesTen CenturiesTen CenturiesTen CenturiesTen Centuries

Group: General Forum Members
Last Login: Friday, July 18, 2014 7:02 AM
Points: 1,140, Visits: 701
Peter,

You going to be at PASS? We clearly need to have a beer


--
Adam Machanic
SQL Server MVP
SQLblog.com: THE SQL Server Blog Spot on the Web
Post #213177
Posted Tuesday, August 23, 2005 3:51 PM


Ten Centuries

Ten CenturiesTen CenturiesTen CenturiesTen CenturiesTen CenturiesTen CenturiesTen CenturiesTen Centuries

Group: General Forum Members
Last Login: Tuesday, July 27, 2010 7:51 PM
Points: 1,244, Visits: 3
I would enjoy that. However, I won't be there. My current contract has me too busy, but being active in this conversation has been worth while .

Your post just beat mine in, but we are thinking alike on this.



Post #213178
Posted Tuesday, August 23, 2005 3:55 PM
SSCrazy

SSCrazySSCrazySSCrazySSCrazySSCrazySSCrazySSCrazySSCrazy

Group: General Forum Members
Last Login: Wednesday, July 9, 2014 9:37 AM
Points: 2,553, Visits: 567
well - I'm not going to PASS so i think I'll just have mine right away...
I know you're going to be one of the speakers Adam...shame I'm going to miss that and all the other names I know so well from this site and otherwise as SQL gurus!

Peter...everytime you feel a diatribe coming on...you should take deep breaths and count to 10 - 100 - whatever it takes...unless you're attending PASS and are patient enough to wait for the promised beer!








**ASCII stupid question, get a stupid ANSI !!!**
Post #213179
Posted Tuesday, August 23, 2005 3:58 PM


Ten Centuries

Ten CenturiesTen CenturiesTen CenturiesTen CenturiesTen CenturiesTen CenturiesTen CenturiesTen Centuries

Group: General Forum Members
Last Login: Friday, July 18, 2014 7:02 AM
Points: 1,140, Visits: 701
One of the main points of my talk is to implement encapsulation and think of stored procedures as black-box APIs



--
Adam Machanic
SQL Server MVP
SQLblog.com: THE SQL Server Blog Spot on the Web
Post #213182
Posted Tuesday, August 23, 2005 4:01 PM
SSCrazy

SSCrazySSCrazySSCrazySSCrazySSCrazySSCrazySSCrazySSCrazy

Group: General Forum Members
Last Login: Wednesday, July 9, 2014 9:37 AM
Points: 2,553, Visits: 567
well - talk about coincidences......that alone calls for a beer!







**ASCII stupid question, get a stupid ANSI !!!**
Post #213183
Posted Tuesday, August 23, 2005 4:06 PM


Ten Centuries

Ten CenturiesTen CenturiesTen CenturiesTen CenturiesTen CenturiesTen CenturiesTen CenturiesTen Centuries

Group: General Forum Members
Last Login: Friday, July 18, 2014 7:02 AM
Points: 1,140, Visits: 701
Agreed... I think I'll go have some now. We have our Boston-area "geek dinner" tonight

http://nerddinner.com/blogs/boston/archive/2005/08/17/6816.aspx



--
Adam Machanic
SQL Server MVP
SQLblog.com: THE SQL Server Blog Spot on the Web
Post #213186
Posted Tuesday, August 23, 2005 4:47 PM
SSC Rookie

SSC RookieSSC RookieSSC RookieSSC RookieSSC RookieSSC RookieSSC RookieSSC Rookie

Group: General Forum Members
Last Login: Wednesday, September 26, 2012 12:03 PM
Points: 28, Visits: 38

Adam,

I think we are going to have to agree to disagree.  Your example  in no way represents business logic.  That is simply a data rule.  Again, I urge you to check your definition of business logic.  As for Peter's trust issue, of course there are constraints on the table, there is referential integrity built into the design of the DB, but that isn't business logic.  Think of it this way, business logic is decided by the business and is subject to change.  Margin trading isn't decided by company ABC, it is decided by a set of rules that superceede that business.  The logic that decides if trader A is qualified for a margin account is business logic and once that is decided then your data validation rule comes into play. 

It would really help me if you could give me a real world example of something you have done that speaks to this issue. 

Also, I am truely hurt that I wasn't invited to the beer discussion at PASS. 

Post #213191
Posted Tuesday, August 23, 2005 5:50 PM


SSC Eights!

SSC Eights!SSC Eights!SSC Eights!SSC Eights!SSC Eights!SSC Eights!SSC Eights!SSC Eights!

Group: General Forum Members
Last Login: Today @ 10:42 AM
Points: 896, Visits: 7,089

Hmmm, getting around the semantics of 'business logic', 'application logic', and 'data validation', I'd like to propose that any logic, the avoidance of which may produce rows in the database which do not reflect true propositions, belongs inside the DBMS and should be a function for the DBMS to enforce.

 





And then again, I might be wrong ...
David Webb
Post #213206
Posted Tuesday, August 23, 2005 6:26 PM


Ten Centuries

Ten CenturiesTen CenturiesTen CenturiesTen CenturiesTen CenturiesTen CenturiesTen CenturiesTen Centuries

Group: General Forum Members
Last Login: Friday, July 18, 2014 7:02 AM
Points: 1,140, Visits: 701

Mike,

No one said that the logic to determine whether or not the trader was qualified for a margin account wouldn't also be represented in the database. As a matter of fact, it probably should be! Otherwise, can you guarantee that the application made the right choice?

The beer, alas, was supposed to be a quaff in the name of agreement, not debate


--
Adam Machanic
SQL Server MVP
SQLblog.com: THE SQL Server Blog Spot on the Web
Post #213209
Posted Wednesday, August 24, 2005 3:17 AM
SSCertifiable

SSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiable

Group: General Forum Members
Last Login: Tuesday, May 6, 2014 5:51 AM
Points: 6,266, Visits: 2,028

I would like to add a bit more of clarity to what I said before:

The minute you declare a Column data type you are using BUSSINESS RULES

The minute you use CHECK Constraints or ANY kind of constraints you are applaying BUSSINESS RULES

The minute you specify LOGIC ORDER of operations in your stored procedures you are using BUSSINESS RULES

 

I am not asking to to program a Maximun of Pontryagin algorithm or Ruffini's root detection algorithm for 1000th root. Just what is best to establish in the database should be there and what is best to write in the middle tier should be there!

The SET based approach to apply certain calculations on the middle tear should be avoided if possible can you think of a 20 Million records going back and forth between severs!? If it is possible to apply those rules on a database I would! then again sometimes is not and I have nothing againts that!

 

IT is in my opinion not a clear cut! 

IF you want maximum flexibility would you make all your columns varchar(8000) and that way you can handle every value and variation in length and data type?

We don't need to go to extremes and we should take care as much as we can of data quality and as close as possible to the data!!

Just my $0.02 or should I said my £0.02 (I am in London today )

Beer!!!

 




* Noel
Post #213303
« Prev Topic | Next Topic »

Add to briefcase «««34567»»»

Permissions Expand / Collapse