SQL Clone
SQLServerCentral is supported by Redgate
 
Log in  ::  Register  ::  Not logged in
 
 
 


It Happens


It Happens

Author
Message
Steve Jones
Steve Jones
SSC Guru
SSC Guru (278K reputation)SSC Guru (278K reputation)SSC Guru (278K reputation)SSC Guru (278K reputation)SSC Guru (278K reputation)SSC Guru (278K reputation)SSC Guru (278K reputation)SSC Guru (278K reputation)

Group: Administrators
Points: 278243 Visits: 19896
Comments posted to this topic are about the item It Happens

Follow me on Twitter: @way0utwest
Forum Etiquette: How to post data/code on a forum to get the best help
My Blog: www.voiceofthedba.com
Dave Poole
Dave Poole
One Orange Chip
One Orange Chip (29K reputation)One Orange Chip (29K reputation)One Orange Chip (29K reputation)One Orange Chip (29K reputation)One Orange Chip (29K reputation)One Orange Chip (29K reputation)One Orange Chip (29K reputation)One Orange Chip (29K reputation)

Group: General Forum Members
Points: 29675 Visits: 3602
It's a harsh fact of life and a quick look down the list of fixes in the older versions of SQL Server reveal some quite nasty bugs.

There is inherrent complexity in having fine grained multi-concurrent data systems. NoSQL is a very broad church so generalisations about NoSQL are risky. What I would say is that the NoSQL solutions are young and there will be bugs that we've forgotten we used to have in RDBMS's.

The companies behind the NoSQL products are energetic, enthusiastic and keen to improve their products. That is something to be welcomed.

LinkedIn Profile
www.simple-talk.com
paul.knibbs
paul.knibbs
SSCertifiable
SSCertifiable (7K reputation)SSCertifiable (7K reputation)SSCertifiable (7K reputation)SSCertifiable (7K reputation)SSCertifiable (7K reputation)SSCertifiable (7K reputation)SSCertifiable (7K reputation)SSCertifiable (7K reputation)

Group: General Forum Members
Points: 7002 Visits: 6240
I always like Maurice Wilkes' quote about this:

"I can remember the exact instant when I realized that a large part of my life from then on was going to be spent in finding mistakes in my own programs."

That was back in the late 40s, I believe, so this has been going on for a while! It doesn't help that SQL, as a language, isn't really well designed for debugging--it's one of the few languages I've used where I find it faster to just rewrite a line of code that isn't working rather than try to figure out why it isn't.
vliet
vliet
SSC Eights!
SSC Eights! (915 reputation)SSC Eights! (915 reputation)SSC Eights! (915 reputation)SSC Eights! (915 reputation)SSC Eights! (915 reputation)SSC Eights! (915 reputation)SSC Eights! (915 reputation)SSC Eights! (915 reputation)

Group: General Forum Members
Points: 915 Visits: 791
SQL has strong roots in relational algebra, this makes it harder to implement but easier to verify. If you use concepts like 'eventual consistency' it is much harder to find out wether everything still acts according too the rules in every possible case. Transactions and isolation levels are also based on a clear set of rules, with the same effect: hard to do it right, but not too hard to check if it's done right.

NoSQL generally means non-relational. Google returns to SQL for access to large data, for several reasons. I don't think SQL and the relational model are the only option when it comes to databases. However, when a model is based on some theoretical foundation, it is easier to prove that certain constraints will always be satisfiied. Does anyone has already encountered a candidate that rivals the relational model in this aspect?
Gary Varga
Gary Varga
SSC-Forever
SSC-Forever (41K reputation)SSC-Forever (41K reputation)SSC-Forever (41K reputation)SSC-Forever (41K reputation)SSC-Forever (41K reputation)SSC-Forever (41K reputation)SSC-Forever (41K reputation)SSC-Forever (41K reputation)

Group: General Forum Members
Points: 41122 Visits: 6562
paul.knibbs (9/25/2013)
...It doesn't help that SQL, as a language, isn't really well designed for debugging--it's one of the few languages I've used where I find it faster to just rewrite a line of code that isn't working rather than try to figure out why it isn't.


Debugging support has been designed into languages in mainstream use for some time now, however, there are plenty of examples of languages where this has had to be shoe horned in. Given that the majority of current popular languages have been designed in an era where Internet development was coming to the fore it is not surprising that these languages have embraced networked development from the off. The trouble is that I have yet to see a mainstream language with a clean implementation for mutlithreaded programming.

How does this relate to the editorial? Without high level abstracts to support such abilities code will be more prone to errors. Memory management is a fine example of this (especially as it highlights something where most languages can take control of but not all languages should).

Gaz

-- Stop your grinnin' and drop your linen...they're everywhere!!!
simon.crick
simon.crick
Valued Member
Valued Member (63 reputation)Valued Member (63 reputation)Valued Member (63 reputation)Valued Member (63 reputation)Valued Member (63 reputation)Valued Member (63 reputation)Valued Member (63 reputation)Valued Member (63 reputation)

Group: General Forum Members
Points: 63 Visits: 101
"embrace the idea that code can be wrong" -- Nathan Marz

Surely this is the wrong approach, as it just gives people an excuse to be lazy.

Code should NEVER be wrong.

It is not difficult to write code that works correctly.

You just need to follow two simple rules:

1) Be crystal clear about the valid set of inputs, and throw an appropriate exception if the input is not in the valid set.

2) If you are not sure whether the logic is correct, break your code into smaller functions/procedures until it is 100% clear that it will work correctly in all cases.

Bugs only arise when people do not follow these simple rules.

Simon
dgreen-1126628
dgreen-1126628
SSC Veteran
SSC Veteran (247 reputation)SSC Veteran (247 reputation)SSC Veteran (247 reputation)SSC Veteran (247 reputation)SSC Veteran (247 reputation)SSC Veteran (247 reputation)SSC Veteran (247 reputation)SSC Veteran (247 reputation)

Group: General Forum Members
Points: 247 Visits: 82
Steve, did you make all those typos in your "It Happens" paragraphs just to make the point that we could still somehow figure out what you were saying? You're so clever! :-)
chrisn-585491
chrisn-585491
SSCertifiable
SSCertifiable (6.7K reputation)SSCertifiable (6.7K reputation)SSCertifiable (6.7K reputation)SSCertifiable (6.7K reputation)SSCertifiable (6.7K reputation)SSCertifiable (6.7K reputation)SSCertifiable (6.7K reputation)SSCertifiable (6.7K reputation)

Group: General Forum Members
Points: 6657 Visits: 2688
It is not difficult to write code that works correctly.
Rolleyes

You can write good code, but chances are you don't write perfect code, all the time. Just because it works, doesn't mean it's correct or right for all situations. Try writing a huge complex business application that runs on three different RDBMS, the desktop and the web, with features to satisfy hundreds of different companies with thousands of users with data collected from millions of people.

(There's a corollary to this about data: "All data is bad, some data is worse.")
simon.crick
simon.crick
Valued Member
Valued Member (63 reputation)Valued Member (63 reputation)Valued Member (63 reputation)Valued Member (63 reputation)Valued Member (63 reputation)Valued Member (63 reputation)Valued Member (63 reputation)Valued Member (63 reputation)

Group: General Forum Members
Points: 63 Visits: 101
paul.knibbs (9/25/2013)
I always like Maurice Wilkes' quote about this:

"I can remember the exact instant when I realized that a large part of my life from then on was going to be spent in finding mistakes in my own programs."

That was back in the late 40s, I believe, so this has been going on for a while! It doesn't help that SQL, as a language, isn't really well designed for debugging--it's one of the few languages I've used where I find it faster to just rewrite a line of code that isn't working rather than try to figure out why it isn't.


That's a lot less depressing than realizing that a large part of your life from now on will be spent in debugging and correcting mistakes in other people's programs. :-)

I have worked on quite a range of projects. Some systems are clearly written by people who care about the quality of their code, and other systems are clearly written by people who are only interested in adding a new technology to their CV before moving on to the next step on their intended career path and don't really care about the trouble they are causing for the people who will have to sort out the mess when they are gone.

Simon
Dave62
Dave62
Hall of Fame
Hall of Fame (4K reputation)Hall of Fame (4K reputation)Hall of Fame (4K reputation)Hall of Fame (4K reputation)Hall of Fame (4K reputation)Hall of Fame (4K reputation)Hall of Fame (4K reputation)Hall of Fame (4K reputation)

Group: General Forum Members
Points: 3977 Visits: 2906
"I hope that's not too gloomy a view of software."

I wrote my first program on punch cards in the late 1970's. Today I do .NET development, SQL development, and SQL Administration. In my experience, I don't think the view that our programs will have bugs or may not work entirely as intended is too gloomy. I don't think that's an excuse to be lazy either. I just think it shows the maturity that's required to realize we're not perfect.

It's delusional to arrogantly deploy a solution and then walk away thinking it's perfect and will never need to be touched again. Crazy

As soon as we have perfect humans we can then start expecting perfect programs. It may be a long wait... Hehe

Until then, I think the best approach is test-driven-development with continuous integration. Continually adding and improving test cases is not lazy. It's a lot of work and there are many places that skip test cases thinking they don't need them. That's lazy.

Test-driven-development with continuous integration acknowledges our imperfections while still trying our best to deliver the highest quality possible.
Go


Permissions

You can't post new topics.
You can't post topic replies.
You can't post new polls.
You can't post replies to polls.
You can't edit your own topics.
You can't delete your own topics.
You can't edit other topics.
You can't delete other topics.
You can't edit your own posts.
You can't edit other posts.
You can't delete your own posts.
You can't delete other posts.
You can't post events.
You can't edit your own events.
You can't edit other events.
You can't delete your own events.
You can't delete other events.
You can't send private messages.
You can't send emails.
You can read topics.
You can't vote in polls.
You can't upload attachments.
You can download attachments.
You can't post HTML code.
You can't edit HTML code.
You can't post IFCode.
You can't post JavaScript.
You can post emoticons.
You can't post or upload images.

Select a forum







































































































































































SQLServerCentral


Search