473,390 Members | 817 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,390 software developers and data experts.

Stored Procedures or Web services

Hi there.

I am developing a client-server application using C# and SQL Server 2005.

Right now, I am using web services to access database, but I'm wondering if
this is the best way. The purpose of using web services is to reuse them
with a web application, for instance. However, I think I could use stored
procedures, and when I need to build a web application, I could then build a
web service to call this stored procedures.

What are the advantages/disadvantages of each one?

Thanks in advance.

Regards,

Marco
Jun 27 '08 #1
3 1730

"Best" is subjective.
You might look at WCF, which gives you better future flexibility.

Check
http://sholliday.spaces.live.com/Blog/cns!A68482B9628A842A!158.entry
or maybe look at Astoria
http://www.microsoft.com/downloads/d...displaylang=en
I have a web application that calls/uses/consumes WCF services.



"Marco Pais" <marco.pais[at]gmail.comwrote in message
news:Ow**************@TK2MSFTNGP04.phx.gbl...
Hi there.

I am developing a client-server application using C# and SQL Server 2005.

Right now, I am using web services to access database, but I'm wondering
if this is the best way. The purpose of using web services is to reuse
them with a web application, for instance. However, I think I could use
stored procedures, and when I need to build a web application, I could
then build a web service to call this stored procedures.

What are the advantages/disadvantages of each one?

Thanks in advance.

Regards,

Marco

Jun 27 '08 #2
On Apr 30, 10:57 am, "Marco Pais" <marco.pais[at]gmail.comwrote:
Hi there.

I am developing a client-server application using C# and SQL Server 2005.

Right now, I am using web services to access database, but I'm wondering if
this is the best way. The purpose of using web services is to reuse them
with a web application, for instance. However, I think I could use stored
procedures, and when I need to build a web application, I could then build a
web service to call this stored procedures.

What are the advantages/disadvantages of each one?

Thanks in advance.

Regards,

Marco
This is what i think..

It will depend on many factors. like where will your c# app going to
run? is this an intranet application or should it also work from your
home (without vpn)

I am assuming that you are going to use Stored procedures with Data
access layer. with the web service/WCF.

If it is intranet app,
you will get better performance if you use your app + Stored
procedures with Data access layer
If your web application will be Asp.net application then you can re-
use the "Stored procedures with Data access layer"
but if you have some other technology you will better off with the web
services + Stored procedures with Data access layer approach.

if your app is going run over internet, then web services/wcf approach
would be better

Jun 27 '08 #3
Marco Pais wrote:
I am developing a client-server application using C# and SQL Server 2005.

Right now, I am using web services to access database, but I'm wondering if
this is the best way.
You should only expose your DAL as web service in very special
circumstances.

You should expose your BLL as web service if you foresee a need to
use it from apps written in different technologies/languages.
The purpose of using web services is to reuse them
with a web application, for instance.
No. See above.
However, I think I could use stored
procedures,
You could.

But the decision whether to use SP's or plain SQL in your DAL is not
related to the interfaces provided by DAL and BLL.

and when I need to build a web application, I could then build a
web service to call this stored procedures.
See above.
What are the advantages/disadvantages of each one?
Web services and stored procedures can not replace each other so
advantages/disadvantages between them does not have any meaning.

Arne

Jun 27 '08 #4

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

Similar topics

3
by: Narayan Appachar | last post by:
Hi, We were able to build stored procedures without any problems till now. Now while building procedures, we are getting the following errors ------------------------------------------ Create...
24
by: Benjamin Doyle | last post by:
In Chip Irek's "A PRIMER ON USING DB2 WITH .NET" (www.15seconds.com), he states that "...ODBC doesn't support DB2 stored procedures. So if you are building an application heavily dependant on...
2
by: Kent Lewandowski | last post by:
hi all, Recently I wrote some stored procedures using java jdbc code (admittedly my first stab) and then tried to implement the same within java packages (for code reuse). I encountered...
5
by: Tim Marshall | last post by:
I was following the thread "Re: Access Treeview - Is it Safe Yet?" with interest and on reading the post describing Lauren Quantrell's SmartTree, I've run into something I don't understand: Stored...
2
by: nbohana | last post by:
I am trying to code an compile a stored procedure without success. So I generated one using Microsoft Visule C# .Net. and it follows. One of the problems is that it will not compile. Some of the...
3
by: Peter | last post by:
I just bought VS.NET Standard 2005. But there aren't any projects for Windows Services and I know that I cannot develop VB.NET Stored Procedures (perhaps no projects for this too) But can I get...
28
by: mooreit | last post by:
The purpose for my questions is accessing these technologies from applications. I develop both applications and databases. Working with Microsoft C#.NET and Microsoft SQL Server 2000 Production and...
2
by: Dean Slindee | last post by:
Anyone know of a location for a simple example of a web service using stored procedures to Read, Insert, Delete and Update rows in MS SQL Server? Thanks, Dean S
3
by: leesquare | last post by:
Hello, I need some help getting output values from my stored procedures when using adodbapi. There's an example testVariableReturningStoredProcedure in adodbapitest.py, and that works for my...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
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
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
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
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

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.