Wrox Programmer Forums
|
BOOK: ASP.NET 2.0 Instant Results ISBN: 978-0-471-74951-6
This is the forum to discuss the Wrox book ASP.NET 2.0 Instant Results by Imar Spaanjaars, Paul Wilton, Shawn Livermore; ISBN: 9780471749516
Welcome to the p2p.wrox.com Forums.

You are currently viewing the BOOK: ASP.NET 2.0 Instant Results ISBN: 978-0-471-74951-6 section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old November 16th, 2008, 09:13 PM
Registered User
 
Join Date: Nov 2008
Posts: 3
Thanks: 0
Thanked 0 Times in 0 Posts
Default CMS - ODBC connections

Hi,

I am new to web design & have had a break from programming for 5 years (used to do a bit before - vb & some sql).

I was recently asked to design a web site - so I bought & read your book Beginning ASP.NET 3.5 from cover to cover. Thanks it was quite helpful.

I am now reading your ASP.net 2.0 Instant results & have been desiging a web site that using CMS logic that I learned from your CMS chapter.

My Web Host only supports SQL ODBC connections (webhost4life). Is there a big difference between using the System.Data.SqlClient & the system.data.oledb providers?

I did not notice this covered in either of these two books?

Can any one point me in the right direction?

Thanks,

Mike
 
Old November 17th, 2008, 08:04 PM
Friend of Wrox
 
Join Date: Jun 2008
Posts: 1,649
Thanks: 3
Thanked 141 Times in 140 Posts
Default

There's no significant difference for most purposes. The biggest differences are either hidden or are related to the dialect of SQL you need to use. The former you don't care about; the latter you are presumably aware of.

There *ARE* libraries out there (check out "Patterns and Practices" on MSDN) that allow you to put an intermediate layer between your code and the actual DB, so that you can easily change from one DB to another without recoding (but of course no matter what you do, you'll almost always find SQL changes needed). But if you don't anticipate needing to change, just stick with the OleDb classes.
 
Old November 18th, 2008, 01:58 AM
Registered User
 
Join Date: Nov 2008
Posts: 3
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Thanks for the response.

I guess I am really showing that I don't understand why an SQL database on a host's site needs to be accessed via ODBC.

 
Old November 18th, 2008, 02:39 AM
Imar's Avatar
Wrox Author
 
Join Date: Jun 2003
Posts: 17,089
Thanks: 80
Thanked 1,576 Times in 1,552 Posts
Default

Quote:
quote:that I don't understand why an SQL database on a host's site needs to be accessed via ODBC.
Neither do I.... ;)

It may be a configuration issue. They may be able to manage your DSN connection centrally, without requiring you to have a user name and password. That's all I can think of.

Many other hosters just allow you to use SQL Server, so it's worth asking your host if you can change it somehow.

And yes, working with the Odbc* objects is pretty similar to the Sql* objects.

Imar


---------------------------------------
Imar Spaanjaars
http://Imar.Spaanjaars.Com
Everyone is unique, except for me.
Author of Beginning ASP.NET 3.5 : in C# and VB, ASP.NET 2.0 Instant Results and Dreamweaver MX 2004
Want to be my colleague? Then check out this post.
 
Old November 19th, 2008, 08:18 PM
Registered User
 
Join Date: Nov 2008
Posts: 3
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Just to clarify for anyone reading the original post.

Whist my host suggested using an odbc connection string, I was able to use the standard System.Data.SqlClient connection string.

So I was wrong in my statement about having to use ODBC.





Similar Threads
Thread Thread Starter Forum Replies Last Post
ODBC connections to Oracle 8i GuidoDB SQL Server 2000 1 January 23rd, 2007 03:17 PM
Help with connections dotnetfreak ASP.NET 1.0 and 1.1 Basics 21 January 18th, 2007 02:07 PM
CMS anshul Pro PHP 2 May 30th, 2005 01:22 AM
ODBC - insert on a linked field - [microsoft][ODBC chimp MySQL 0 April 7th, 2005 04:44 AM
Connections saulodet ADO.NET 2 January 2nd, 2004 04:55 PM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.