Applies To:
  • CitectSCADA 5.xx

How do I establish a link from Microsoft Query (V8.00) to my Citect ODBC server? 

The online documentation details how to access the Citect ODBC server using MS Query (V2.00) which is shipped with Office95. MS Query (V8.00) shipped with Office97 requires a different setup.

Unlike the 95 version, User DSNs are not used by MS Query 97. Instead it uses File DSNs which by default are stored in the Program Files\Common Files\Odbc\Data Source folder. File DSN's are not stored in the Windows registry, they are text files given the .DSN extension. When you connect to an existing data source, only the available File DSNs that are stored on that PC are displayed. MS Query 97 does not display User or System DSNs. The simplest solution is to create a File DSN that points to a User DSN.

To create a File DSN that points to a User DSN, do the following:

  1. Use a text editor, eg Notepad, and create a file containing the following two lines:
    where <MyUserDSN> is the name of an existing User DSN that you have created via the ODBC icon in the Control Panel.
  2. Click Save As on the File menu type a name that includes a .DSN file extension. For example, "Citect_File.dsn" is a valid name. Include the quotation marks to ensure that the .DSN file name extension is added correctly. Save it to the default File DSN directory listed above, then it will appear in the DSN list box without needing to go Browsing.
  3. Open the ODBC Manager from the Control Panel and ensure you can see your newly created File.DSN.
  4. (This step as per Citect online help) Open the ODBC Manager from the Control Panel and ensure you have created a User DSN called <MyUsrDSN>.
    eg Select Citect Driver and Click Finish button
    Enter "Citect" in the Data Source field (ie <MyUsrDSN>)
    Enter Computer Name in the Host field

Now when you run MS Query you should be able to select your File. DSN from the list.