Wednesday, September 15, 2010

Connecting to your SQL Server Database

If you have AccuSQL and have set up the MS SQL Server database and transferred your database to it, then you are now ready to connect other installations of AccuSQL to this SQL Server database.  This blogs shows you how to do this.

NOTE: The steps are the same whether you are connecting a regular AccuSQL installation to the SQL Serer database or if you are connecting the SQL Computer Lab Plug-in Advanced software. 

These steps assume that you already have completed transferring your database and have an existing AccuSQL database on the SQL Server.  If you have not done this already, then start by checking the “Creating your SQL Server Database” blog.

There are more than one way to connect the AccuSQL or Plugin SQL software its SQL Server database. First lets take a look how to do that using AccuSQL or Plug-in software itself. Here are the steps:

clip_image002

1)  Launch AccuSQL software and log in as a root administrator.

2) In the bottom left area of AccuSQL, click on the Expanded View radio button.

3) Now access the Database --> Database Location screen and click the SQL Server radio button and click the Next button.

4) Select “SQL Server” option and click “Next”.

5) In the Application Share Path area specify a shared network folder that everyone has full access rights (Full control, read, write, modify).

6) In the SQL server connection info area, enter your server name, authentication mode (Windows authentication is preferred but SQL server authentication needs less expertise), and if authentication is SQL server mode your username and password – limited account’s username and password if you opted to create it.

7) In the Database drop-down menu, select the database you created earlier. Tip: After entering server, username, password information click on Database drop down’s ‘down arrow’. If it displays a list populated with your database in it then that verifies that you have a valid connection to the SQL Server database.

8) Now press the Test Connection button. If all is well, you will get a "Test connection succeeded" message. If not, you will get an error message. Verify all the information is correct and retest until you get a success message.

9) Press the Save button and then press Close Form.

10) Now press the main “Exit AccuSQL” button to close the application.

11) When you re-launch AccuSQL, you will be connected to the SQL Server database. Congratulations!

A second way to connect

The second way is easier and faster.

1. Go to your application folder using windows explorer (right click application shortcut, select properties and then “Find target”. In Windows 7 you can also right click and directly select “Open file location”). The application folder is typically “c:\Program Files\AccuSQL”.

2. Locate “SetDataPath.exe” file and run it by double clicking it.

3. You would see the same user interface that you get when you use Database -> Database Location in AccuSQL.

4. Fill in the information as explained above and click “Save”.

clip_image004

Yet a third way to connect!

The third way doesn’t actually create and save the connection information as the previous two above did. Instead it creates an encrypted connection information file in XML format that you can copy and use on multiple computers. This is especially useful to create the connection information on one computer and then deliver it to multiple Plug In computers without manually entering the information for each computer. Here is how you do it:

1) Go to your application folder using windows explorer (right click application shortcut, select properties and then “Find target”. In Windows 7 you can also right click and directly select “Open file location”). The application folder is typically “c:\Program Files\AccuSQL”.

2) Locate “CLDataPath.exe” file and run it by double clicking.

3) You would see the same user interface that you get when you use Database -> Database Location in AccuSQL.

4) Fill in the information and click “Save”.

5) You will see a ‘Save as’ dialog box prefilled with “DbCon.XML”. Change the location if you need to and save. This will create a file named “DBCON.XML”. Important: Do NOT rename that file.

6) Copy this file to a USB stick or network drive which you can access from other computers (you may also want to copy “DbConnector.exe” file from your application folder. This file is normally installed on initial installation and already exists on other computers but you may have a later version on your application folder. It is recommended that you copy and use the one from your application folder).

7) Go to any of the client computers and copy “DbCon.xml” file to application folder (and “DbConnector.exe” as well). Important: Copy the file(s) into application folder and not into any other folder.

8) After the file(s) are copied, double click dbconnector.exe to run it. It would create the necessary

Technorati Tags: ,

registration for connecting to database. You are done. Repeat steps 7 and 8 on other computers.

clip_image006clip_image008

No comments:

Post a Comment