In Visual Studio when a developer wants to create strong typed classes for database tables either for the conventional TableAdapter or Entity Framework there is a place in the process where a dialog is displayed as shown below. I will show you how to do this at runtime and a bit more.

Full source found on MSDN

Example that permits customizing the dialog where in this case I have added a context menu to show my server.
Name:  Figure2.jpg
Views: 1434
Size:  64.1 KB

The sample project shown here permits using the dialog followed by creating SQL statements and also exporting data in a comma delimited text file.
Name:  Figure3.jpg
Views: 1427
Size:  56.6 KB