To create an ODBC data source. 1.You might create a file DSN in designated directory. It's a ".ini" like text file. You can examine it for an analogy. Default directory is "Program Files\Common Files\ODBC\Data Sources". 2.You might create registry keys for User or System DSNs, respectively under the keys below. You can also examine them. HKCU\Software\ODBC\ODBC.INI HKLM\SOFTWARE\ODBC\ODBC.INI BTW, I'm speaking mostly for XP OS because the others may somewhat differ. Additionally, you don't have to create any kind of DSN, you can open your connection on the fly in your code by a proper connection string like below. "DRIVER=SQL Server;SERVER=%s;DATABASE=%s;UID=%s;PWD=%s" You may need to use "DRIVER=SQL Native Client" for 2008. You can also execute DDL scripts to create your schema using CDatabase::ExecuteSQL(). To do this, you can open your database connection using string below with an administrator user/password. "DRIVER=SQL Server;SERVER=%s;DATABASE=master;UID=sa;PWD=%s"