.NET Answers

ASP.NET, HTML, CSS, Visual Studio, CSharp, VB.NET and other programming items of interest.
Subscribe
  • Home
  • About Me
  • Advertising
  • Click Here to Ask a question
    • Privacy Policy
  • Site Map

SQL For Developers – 9 Reasons to bother

August 13, 2008 By: Dave

F03I0081 If you are a developer like I am, you’ve probably gotten by with pretty simple SQL for quite a while. In fact, my experience has been that developers don’t get much past SELECT, INSERT, UPDATE, and DELETE with the associated WHERE and ORDER BY clauses that are necessary to get anything done as a developer.

But there are times when knowing more would be helpful. So today, I thought I’d start a short series on helpful SQL for developers. Keep in mind, I’m a developer, not a DBA. I’m sure there may be better ways of doing some of the things I suggest. However, everything I suggest will be better than trying to do it all from your CSharp or VB.NET code.

Let’s look at some of the reasons a developer should learn SQL:

  • If you only use the statements above, your code is almost certainly making more trips to the database than it should, or needs to. Simply put, the performance of your applications is suffering.
  • Prior to ASP.NET, and, to a lesser extent, with it, you open yourself up to the possibility of SQL injection attacks because you are only using the statements above.
  • You are probably avoiding a good three-tiered architecture because it practically requires you to write stored procedures. This is making your code harder to maintain.
  • You are probably using the SqlDataObject for your data binding. As a result, you are frustrated with the errors this is causing you in your updates that you have very limited ways of tracking down.
  • By refusing to learn the DDL portion of SQL, you are limited in how you can version your database. If you learn DDL, you’ll be able to version your database schemas in a similar manner to how you version your source code.
  • If you are writing DotNetNuke modules that access a database, you’ll need this information.
  • By learning SQL, your SQL will become less of a hack, making this part of your development effort more efficient.
  • Even if you have a DBA who is responsible for writing this code for you, wouldn’t it be helpful to be able to speak his language? I’ve been programming for 21 years now and I’ve only met one DBA who knows more than I do about SQL. Considering that I would not consider myself an expert in SQL this reflects poorly on the DBAs that I’ve had to work with. What this means in practical terms is, you are a lot more likely to get the SQL code you want into your database if you can just hand it to your DBA and say, “Do this,” rather than asking for a stored procedure that does something. Code is the best specification.
  • Having a firm grasp of SQL will make you a more valuable programmer. This is the best reason of all.

Stick with me over the next several weeks and we’ll introduce some SQL that you can use in your daily programming life.

 

Other post in SQL For Programmers
  • SQL For Developers - 9 Reasons to bother - August 13th, 2008
  • SQL for Programmers - CREATE/DROP Database - August 20th, 2008
  • SQL For Programmers - CREATE TABLE - August 22nd, 2008
  • SQL For Programmers - ALTERing the TABLE - September 1st, 2008
  • SQL For Programmers - Finding a String - September 3rd, 2008
  • SQL For Programmers - Finding IN a List - September 8th, 2008
  • SQL For Programmers - Stored Procedures (Better than LINQ) - September 10th, 2008
  • SQL For Programmers - Stored Procedure Basics - September 16th, 2008
  • Basic SQL Commands - SQL For Programmers - September 18th, 2008
  • SQL IF/WHILE Blocks - SQL For Programmers - September 30th, 2008
  • SQL WHILE - SQL For Programmers - October 2nd, 2008
  • Temporary Tables - SQL For Programmers - October 7th, 2008
  • SQL CURSOR - SQL For Programmers - October 13th, 2008
  • SQL CURSOR Performance - SQL For Programmers - October 22nd, 2008
  • Random in SQL - SQL For Programmers - November 4th, 2008
  • SQL - Filtering WHERE condition on two rows - November 26th, 2008
  • SQL - Transactions - April 15th, 2009

If you're new here, you may want to subscribe to my RSS feed. Thanks for visiting!

Related Post

  • SQL – Transactions
  • SQL – Filtering WHERE condition on two rows
  • Random in SQL – SQL For Programmers
Bookmark to:

Add to Del.icio.us Add to digg Add to DotNetKicks Add to DZone Add to Facebook Add to Slashdot Add to Stumble Upon Add to Technorati
Hide Sites
Tags: sql

5 Responses to “ SQL For Developers – 9 Reasons to bother ”

  1. # 1 Dew Drop - August 13, 2008 | Alvin Ashcraft's Morning Dew Says:
    August 13th, 2008 at 8:33 am

    [...] SQL for Developers – 9 Reasons to Bother (Dave M. Bush) [...]

  2. # 2 Web 2.0 Announcer Says:
    August 14th, 2008 at 2:14 pm

    SQL For Developers – 9 Reasons to bother…

    [...]If you are a developer like I am, you’ve probably gotten by with pretty simple SQL for quite a while. In fact, my experience has been that developers don’t get much past SELECT, INSERT, UPDATE, and DELETE with the associated WHERE and ORDER BY…

  3. # 3 ben Says:
    August 14th, 2008 at 5:41 pm

    I totally agree with this. Before my current job SQL was something I knew about, and could write if I needed to but didnt really have a firm grasp of.

    All of a sudden I was writing SQR reports with upto 3 A4 pages of SQL. I learnt all sorts of tricks for getting SQL to do things and basiclly improved my understanding beyond all recognition.

    I have since moved away from SQR but when looking at and SQL now I am thinking of performance and how to improve it. Frankly it was one of the most useful things I have done.

  4. # 4 Weekly Link Post 55 « Rhonda Tipton’s WebLog Says:
    August 15th, 2008 at 9:38 pm

    [...] The .NET Answers blog gives us 9 Reasons a developer should learn SQL. [...]

  5. # 5 SQL Server Stuff « QuantuMatrix’s Weblog Says:
    April 15th, 2009 at 11:19 am

    [...] SQL For Developers – 9 Reasons to bother – August 13th, 2008 [...]

← DotNetNuke – Data Access Layer Alternative
DotNetNuke – Modules – Linking within the module →
  • Search

  • Subscribe

    U COMMENT
    I FOLLOW

    Subscribe in a reader

    OR

    Subscribe via e-mail

    Enter your email address: 

    Delivered by FeedBurner

     

  • Follow Me

    • Twitter
    • FaceBook
    • Digg
    • StumbleUpon
    • Propeller
    • Delicious
    • Plaxo

     

  • Recent Posts

    • ASUS Eee PC 1005HA-PU1X-BK Black Netbook
    • jQuery – Date Picker
    • Using VB.NET From CSharp
    • iTextSharp – Adding Images
    • Hungarian Notation – Use What Works, Spit Out The Bones
    • Pre Order Windows 7
    • jQuery Dialog – With Validation Controls
    • iTextSharp – The easy way
    • Structure of my ASP.NET Web Applications
    • 35% Off Accronis True Image 2009 Home
    • VB.NET Hide Module Name
    • ASP.NET/VB.NET – Video Training
    • Does jQuery Make Us Lazy?
    • PDFs Using iTextSharp
    • Programming SEO – Ping



  • Advertise on this site through Lake Quincy Media
  • DotNetNuke Sponsor

     

    Most Valuable Blogger
  • Sponsor

  • Categories

    • Advanced CSharp
    • Advanced VB.NET
    • ASP.NET MVC
    • Did you know
    • DotNetNuke – Module Development
    • DotNetNuke – Skinning
    • internationalization
    • iTextSharp
    • jQuery
    • none
    • Seach Engine Optimization
    • Silverlight
    • SQL For Programmers
    • Twitter
    • winforms
  • Cloud

    .net ajax architecture asp.net book books containers csharp css dal dataset datasets dotnetnuke events gridview images internationalization internet explorer javascript jQuery json linq listview modules ms-sql MVC objectdatasource programming reflection seo Silverlight skinning sql testing tsql tutorial Twitter twitterizer vb.net video view Vista visual studio webservice WordPress
  • Archives

    • July 2009
    • June 2009
    • May 2009
    • April 2009
    • March 2009
    • February 2009
    • January 2009
    • December 2008
    • November 2008
    • October 2008
    • September 2008
    • August 2008
    • July 2008
    • June 2008
    • May 2008
    • April 2008
    • March 2008
    • February 2008
    • January 2008
    • December 2007
    • November 2007
    • October 2007
  • Meta

    • Log in
    • Entries RSS
    • Comments RSS
    • WordPress.org
    • Privacy Policy
  • Calendar

    August 2008
    S M T W T F S
    « Jul   Sep »
     12
    3456789
    10111213141516
    17181920212223
    24252627282930
    31  
  • Blogroll

    • Alvin Ashcraft’s Morning Dew
    • ASP.NET Consulting
    • Life Hacker
    • Remember Anything
    • The Price of Their Toys
    • Uncategorized Thought


.NET Answers © 2007 - 2008 All Rights Reserved.
Entries and Comments.