E
ebrastow
Hi folks,
I'm a VB newbie - been using PowerBuilder for 12 years and thought I'd
see how Visual Basic has come along these days.
I'm using MS Visual Studio 2005 Professional, trying to connect to a
SQL Server 2000 Standard (SP4) database on another machine.
For weeks, whenever I've had time to try this, I have gone through the
"Add New Data Source..." wizard, filled in all of the information
appropriately, and at the end, when it should be showing me my tables
and it's at the last screen of the wizard where it says, "Which
database objects do you want in your dataset?", it's showing me the
following error:
--
An error occurred while retrieving the information from the database.
Failed to retrieve data for this request.
An exception occurred while executing a Transact-SQL statement or
batch.
Line 8: Incorrect syntax near "1".
--
This happens consistently. Here is the connection string it's
generating (I've changed the names to protect the guilty):
"Data Source=SERVERNAME;Initial Catalog=databasename;Persist Security
Info=True;User ID=username;Password=userpassword"
I have verified that everything is typed correctly.
Now, what's weird is that as I was playing around with this this
morning, I came across something interesting. It turns out that in the
"Server Explorer" pane, where it lists Database Connections, I can
expand this very same connection and it shows me the tables, views,
SP's, etc... in my database. It's the very same connection, and it
works in the server pane but not in the Data Sources pane.
What the heck!??
Any help would be very much appreciated. I'd like to be sure my
database connections are on solid footing before I go trying to learn
VB in earnest.
Evan
I'm a VB newbie - been using PowerBuilder for 12 years and thought I'd
see how Visual Basic has come along these days.
I'm using MS Visual Studio 2005 Professional, trying to connect to a
SQL Server 2000 Standard (SP4) database on another machine.
For weeks, whenever I've had time to try this, I have gone through the
"Add New Data Source..." wizard, filled in all of the information
appropriately, and at the end, when it should be showing me my tables
and it's at the last screen of the wizard where it says, "Which
database objects do you want in your dataset?", it's showing me the
following error:
--
An error occurred while retrieving the information from the database.
Failed to retrieve data for this request.
An exception occurred while executing a Transact-SQL statement or
batch.
Line 8: Incorrect syntax near "1".
--
This happens consistently. Here is the connection string it's
generating (I've changed the names to protect the guilty):
"Data Source=SERVERNAME;Initial Catalog=databasename;Persist Security
Info=True;User ID=username;Password=userpassword"
I have verified that everything is typed correctly.
Now, what's weird is that as I was playing around with this this
morning, I came across something interesting. It turns out that in the
"Server Explorer" pane, where it lists Database Connections, I can
expand this very same connection and it shows me the tables, views,
SP's, etc... in my database. It's the very same connection, and it
works in the server pane but not in the Data Sources pane.
What the heck!??

Any help would be very much appreciated. I'd like to be sure my
database connections are on solid footing before I go trying to learn
VB in earnest.
Evan