By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
446,361 Members | 1,955 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 446,361 IT Pros & Developers. It's quick & easy.

Please help with ConnectionString to SQLAnywhere 5.0

P: n/a
Hi all,

i have a client with an old working app. in PowerBuilder for which i
need to create new modules.
The db is sqlanywhere 5.0.4
The db is configured in ODBC.
Now, i don't seem to be able to connect to this db.

Can anyone help me with the connectionstring and maybe references to
add?

string connectionString = "Data Source=Ghoenix;uid=dba;pwd=gerling";
Conn = new OdbcConnection(connectionString);

try{Conn.Open();}
catch(Exception ex){MessageBox.Show(ex.ToString());};

He keeps giving : datasource & driver not found...

Help would greatly be appreciated,
Oswald
Nov 16 '05 #1
Share this Question
Share on Google+
2 Replies


P: n/a
i found it myself
SQLAnywhere 5.0 is supported by ODBC 2.x instead of 3.x
And this string worked just fine!

For everybody's information (if ever needed):
---------------------------------------------
String ConnectionString =
"Provider=MSDASQL;DSN=Ghoenix;userid=dba;password= gerling";
OdbcConnection myConnection = new OdbcConnection(ConnectionString);
myConnection.Open();

os**************@skynet.be (oswald verlinden) wrote in message news:<1c**************************@posting.google. com>...
Hi all,

i have a client with an old working app. in PowerBuilder for which i
need to create new modules.
The db is sqlanywhere 5.0.4
The db is configured in ODBC.
Now, i don't seem to be able to connect to this db.

Can anyone help me with the connectionstring and maybe references to
add?

string connectionString = "Data Source=Ghoenix;uid=dba;pwd=gerling";
Conn = new OdbcConnection(connectionString);

try{Conn.Open();}
catch(Exception ex){MessageBox.Show(ex.ToString());};

He keeps giving : datasource & driver not found...

Help would greatly be appreciated,
Oswald

Nov 16 '05 #2

P: n/a
Still had problems with security issues, but this one is a winner :

String ConnectionString = "Provider=MSDASQL;DSN=Ghoenix;UID=dba;PWD=gerling" ;
os**************@skynet.be (oswald verlinden) wrote in message news:<1c**************************@posting.google. com>...
Hi all,

i have a client with an old working app. in PowerBuilder for which i
need to create new modules.
The db is sqlanywhere 5.0.4
The db is configured in ODBC.
Now, i don't seem to be able to connect to this db.

Can anyone help me with the connectionstring and maybe references to
add?

string connectionString = "Data Source=Ghoenix;uid=dba;pwd=gerling";
Conn = new OdbcConnection(connectionString);

try{Conn.Open();}
catch(Exception ex){MessageBox.Show(ex.ToString());};

He keeps giving : datasource & driver not found...

Help would greatly be appreciated,
Oswald

Nov 16 '05 #3

This discussion thread is closed

Replies have been disabled for this discussion.