473,405 Members | 2,160 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,405 software developers and data experts.

Merits of using a DAL

In an environment such as VS which allows great integration of the Database
design components visually in the IDE, and given that a target app is will
be deployed on a single machine (ie. not n-tier or client server), I'm
debating the concept of using a DAL.

Other than logical design, I cannot see a benefit of using it.

Can anyone offer any opinions?

Thanks
Nov 17 '05 #1
2 1283
If your program will be required to migrate to some other database such as
if you start out with access and think that you may move to SQL later or if
the code is for some project that may require future expansion, re-write for
Avalon, addition of a web-interface then use the DAL idea.

If not then don't bother to complicate your life any more than you need to.

--
Bob Powell [MVP]
Visual C#, System.Drawing

Ramuseco Limited .NET consulting
http://www.ramuseco.com

Find great Windows Forms articles in Windows Forms Tips and Tricks
http://www.bobpowell.net/tipstricks.htm

Answer those GDI+ questions with the GDI+ FAQ
http://www.bobpowell.net/faqmain.htm

All new articles provide code in C# and VB.NET.
Subscribe to the RSS feeds provided and never miss a new article.

"Paul Aspinall" <pa**@aspy.co.uk> wrote in message
news:I2******************@fe3.news.blueyonder.co.u k...
In an environment such as VS which allows great integration of the
Database design components visually in the IDE, and given that a target
app is will be deployed on a single machine (ie. not n-tier or client
server), I'm debating the concept of using a DAL.

Other than logical design, I cannot see a benefit of using it.

Can anyone offer any opinions?

Thanks

Nov 17 '05 #2
Paul Aspinall wrote:
In an environment such as VS which allows great integration of the
Database design components visually in the IDE, and given that a
target app is will be deployed on a single machine (ie. not n-tier or
client server), I'm debating the concept of using a DAL.

Other than logical design, I cannot see a benefit of using it.

Can anyone offer any opinions?


Well, this is a typical coder's approach -- go with the tools and be
done with it. But unfortunately, once you wear a tester's hat, or an
architect's hat, things aren't that easy anymore.

First, you cannot unit test your application in a meaningful way,
because you're unit is the entire application. There's no way to "mock"
or "stub" the DAL without a proper DAL. This also means that there's no
easy way to swap out implementations (e.g. Oracle vs. SQL Server), if
that ever becomes a requirement -- there's no abstraction layer
protecting the rest of your application from data access implementation
details.

Second, unless you're data access code is utterly trivial, I'm sure
that you'll find repeating similar data access code all over the place.
It doesn't matter whether it's handwritten or generated by tools. It
violates one of the most fundamental design principles: Don't repeat
yourself. And it quickly becomes a maintenance nightmare.

If you're asking as a hobbyist though, things are different -- do
whatever you're most comfortable with ;-)

Cheers,
--
http://www.joergjooss.de
mailto:ne********@joergjooss.de
Nov 18 '05 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

3
by: Joe | last post by:
Hi all, We have a website which has some html(static), asp(pages with forms) and some .aspx (pages with forms) pages. Can someone tell me the advantages of having the entire website in .aspx vs...
852
by: Mark Tarver | last post by:
How do you compare Python to Lisp? What specific advantages do you think that one has over the other? Note I'm not a Python person and I have no axes to grind here. This is just a question for...
14
by: Paddy3118 | last post by:
This month there was/is a 1000+ long thread called: "merits of Lisp vs Python" In comp.lang.lisp. If you followed even parts of the thread, AND previously used only one of the languages AND...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.