Building Connection Strings the easy way

Chris Webb recently blogged about a conversation that a group of us were having where the topic of the Timeout connection string property came up.

Chris asked how I found out about this property. The technique I used is handy for exploring all types of connection string properties, so I thought I would share it here.

  1. Create a new text document on your desktop.

  2. Rename it to test.udl (its the extension that matters, the name can be anything you like)

  3. double click on this file and it brings up a "Data Link Properties" dialog.

  4. Go to the provider tab and set the provider to "Microsoft OLEDB Provider for Analysis Services 9.0" (or choose any another provider in which you are interested.)

  5. You can then work your way through the dialog setting connection properties,

  6. Under the "All" tab you will find and entry for timeout. (along with all the other properties that the selected provider supports.)

  7. Once you have set all the properties you want, open up the .udl file using notepad you will see a connection string with all the appropriate settings.

This is a great way to generate connection strings and make sure that you have all the settings spelt right. Enjoy!

Print | posted on Sunday, November 5, 2006 9:39 PM