\title{Dynamic Query Form for Relational Database}
\author{Priyanka Gupta$^{1}$, Rakesh Kumar Singh$^{2}$, Rambha Agrahari$^{3}$ \\
$^{1,3}$M.Tech Scholar, CSE, Kamla Nehru Institute of Technology, Sultanpur, U.P., India \\
$^{2}$Associate Professor, CSE, Kamla Nehru Institute of Technology, Sultanpur, U.P., India}

\begin{abstract}
There is a rapid development of the morden scientific database and internet database. These databases have thousand numbers of relations and attributes. So static query form does not work with a large number of relations and attributes, as they do not satisfy many ad-hoc database queries on the real world databases. Thus there is a requirement of a system which will satisfy the user requirement and generate the query form dynamically at the run time. In this paper we propose the Dynamic Query Form (DQF), which is going to provide the solution of the large and heterogeneous database. DQF captures the user's interest and provide the rank query form component, which is useful for the user to make his/her decision. DQF is the iterative process and each iteration is guided by the user. In each iteration system generates the ranking list of form component automatically and user can add any component according to his/her requirement. The component ranking is generated by capturing the user preference. Now user can fill the enrich query form and execute the query and the result will be shown to the user. This process is repeated until the user is satisfied.
\end{abstract}

\textbf{Keywords:} Query form, Query execution, User interaction, Query form generation.

\section{Introduction}
A database is not useful until a query interface does not provide to handle the database. If the user can not communicate with the database, there is no use of that database. Structured query can be written in SQL and XQuery but it is not good for that type of user who does not know anything about SQL. For this reason, Query form is the easiest way for that type of user because they just fill the blanks in the form. That is the reason Query form is one of the most widely used technique for providing the interface to the database. Traditional Query form are predefined by the developers or DBA which does not satisfy the user ad-hoc query as the database become large and complex.

There are many existing database development tools such as Easy Query \cite{1}, Cold Fusion \cite{2}, Microsoft access, which will provide mechanism to customize the query form by the user but if the user is not familiar with these database tools then it is not easy to work with large database. DQF will generate the query form dynamically and each iteration in DQF consist Query form enrichment and Query execution. The basic query forms are provided to the user and this form will be enriched iteratively using the user and system interactions till the user is satisfied with the query result.

\section{Query Form Technique}
How non expert user makes use of the relational database is a challenging topic. Non expert user can interact with the database using Query By Example (QBE) \cite{3} and Query Form.

\subsection{Query By Example}
It is a database query language for relational database. It is the first query language used to create visual tables where the user can enter commands, example elements and condition.

Example form contacts- \\
Name: \hspace{1cm} X \\
Address: \\
City: \\
State: \hspace{1cm} Y \\
Pin code:

Resulting SQL : \\
SELECT * FROM CONTACTS \\
WHERE NAME='X' \\
AND STATE='Y';

\subsection{Customized Query Form}
There are many existing tools for the developers to create or customize the query form such as SAP, Microsoft access and so on. The problem with these tools is that, they are for the professional developers who are familiar with their database. These tools are not for end user who does not know anything about the database.

\subsection{Automatic Static Query Form}
It is the data driven technique, which first finds a set of data attributes which are mostly queried. Then based on these attributes query form will be generated. So it will applied clustering algorithms on the historical queries to find the new queries. Then query form generated based on these new queries. The problem with this technique is that, if the database is very large and complex then user query could be diverse. In such cases, if we generate lots of forms in advance still it does not satisfies the user requirements. Another problem is that if we generate lots of query forms then how user will know which form will satisfies his/her requirement.

\section{Existing System}
Traditional query forms are predefined by the developers or DBA. As the database become large and complex, static query forms does not satisfy the user requirements.