Wrox Programmer Forums

Need to download code?

View our list of code downloads.

Go Back   Wrox Programmer Forums > SQL Server > SQL Server 2005 > SQL Server 2005
Password Reminder
Register
| FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read
SQL Server 2005 General discussion of SQL Server *2005* version only.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the SQL Server 2005 section of the Wrox Programmer to Programmer discussions. This is a community of tens of thousands of software programmers and website developers including Wrox book authors and readers. As a guest, you can read any forum posting. By joining today you can post your own programming questions, respond to other developers’ questions, and eliminate the ads that are displayed to guests. Registration is fast, simple and absolutely free .
DRM-free e-books 300x50
Reply
 
Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old October 4th, 2006, 05:30 PM
Registered User
 
Join Date: Oct 2006
Location: Portsmouth, , .
Posts: 2
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via MSN to raktol
Default sqlserverexpress

Just a quick one...

I have looked and looked etc but...no definitive result.

I maintain a legacy database app written in VB6 using SQL7. Now I now that the app works using sql2000. With SQLserverxpress (which would easily serve our needs) using the same connection string the response is "sql server could not be found"...

I have read that sqlexpress should be happy using a legacy connection string etc ie provider=SQLOLEDB.1. But is doesnt..

(1) is this because of the way that I have installed SQLExpress.
(2) SQLOLEDB no longer works..

I have used the native client and that works to a certain degree, however, the app uses a custom dll file with hardwired connectons strings that use sqloledb.

most of the app works but some parts dont because of the referenced dll....
Ideally I would like to keep using the original connecton string..

So far I have not seen anything definitive..ie. it wont work use the native provider...

this is the connection string that works with anything prior to sqlexpress

    MyConnString = "Provider=SQLOLEDB.1;Persist Security Info=False;User ID=" & User & ";Password=" & strPassword & ";Initial Catalog=" _
        & DBName & ";Data Source=" & ServerName & ";Connect Timeout=50"


So question is..is it a server config problem, or a case of changing the connection string and subsequent code

cheers


Reply With Quote
  #2 (permalink)  
Old October 5th, 2006, 03:49 PM
SQLScott's Avatar
Wrox Author
 
Join Date: Dec 2004
Location: Wellington, FL , USA.
Posts: 338
Thanks: 0
Thanked 2 Times in 2 Posts
Default

raktol, we have been sucessful using the following connection string format:

Server=servername;uid=username;PWD=password;Databa se=database;

Scott Klein
Author - Professional SQL Server 2005 XML
http://www.wrox.com/WileyCDA/WroxTit...764597922.html
Reply With Quote
  #3 (permalink)  
Old October 8th, 2006, 05:31 AM
Registered User
 
Join Date: Oct 2006
Location: Portsmouth, , .
Posts: 2
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via MSN to raktol
Default

HI SQLScott,

Cheers for the prompt reply..

I noticed your connection string doesnt specify the data provider.

have you configured a DSN for sql2005?

Sorry if this is a dumb question

regards



Reply With Quote
  #4 (permalink)  
Old October 8th, 2006, 12:11 PM
SQLScott's Avatar
Wrox Author
 
Join Date: Dec 2004
Location: Wellington, FL , USA.
Posts: 338
Thanks: 0
Thanked 2 Times in 2 Posts
Default

Hi, yes, this is for sql server 2005. You can also use this one:

Data Provider=SQLNCLI;Server=servername;uid=username;PW D=password;Database=database;

Scott Klein
Author - Professional SQL Server 2005 XML
http://www.wrox.com/WileyCDA/WroxTit...764597922.html
Reply With Quote
Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
SQLServerExpress not allow remote connection VictorVictor ASP.NET 2.0 Professional 21 October 24th, 2006 03:15 PM



All times are GMT -4. The time now is 02:35 PM.


Powered by vBulletin®
Copyright ©2000 - 2019, Jelsoft Enterprises Ltd.
© 2013 John Wiley & Sons, Inc.