Search Forum
(53671 Postings)
Search Site/Articles

Archived Articles
712 Articles

C# Books
C# Consultants
What Is C#?
Download Compiler
Code Archive
Archived Articles
Advertise
Contribute
C# Jobs
Beginners Tutorial
C# Contractors
C# Consulting
Links
C# Manual
Contact Us
Legal

GoDiagram for .NET from Northwoods Software www.nwoods.com


 
Printable Version

QueryBuilder in C-Sharp
By Neelam Iyer

This application is that of a QueryBuilder in CSharp.This application is for Beta2 SDK version of DotNetFramework.I have used Oracle as the backend.For database connectivity and related operations, I have used System.Data.Odbc.dll file. For this application you'll have to download and install Oracle.NET from the Microsoft site. And yes you need the Microsoft.Net Framework installed on your machine(That goes without saying).The path of System.Data.Odbc.dll file may differ from the path of your application.If you wish you can copy the dll file in the folder in which you have your application.

How the application works:

The GUI is a Windows Form which has a Mainmenu,Buttons,TextBox ,ListBox and Statusbar. You can get connected to the database by clicking on the Connect button .You have to provide DSN name,Username and Password to connect to the database(assuming you are using Oracle as the database). You can select all the tables by clicking on the UserTables button.Only five tables are displayed at a time and you can click the NextRowSet button to move to the next five tables and so on. There is an execute button to execute any query.If the query is for selecting records ,again only five records are displayed per page and you can click the NextRowSet button to move to the next five records and so on. The disconnect button gets you disconnected from the database. Mainmenu consists of three Menuitems File,Edit and Status.You can use the different File menu items to perform file related operations.Edit Menuitems consist of cut,copy and paste options.Status menuitem controls the visibility of the statusbar.

There are two files queryanal.cs and connect.cs.

Compile the files by using the following command:
csc /r:System.Data.Odbc.dll queryanal.cs connect.cs

Download QueryBuilder.zip