ASP to do Query Analyzer (Query Analyzer) (III)

Source: Internet
Author: User
Query Analysis Sqlultimate.asp--part C

<title>BuildSQL</title>
<!--#include file= "datatypelib.asp"-->

<script language= "JavaScript1.2" type= "Text/javascript" >

<!--
function AddField (field) {
Strfield = Document.sqlForm.strSQL.value;
Strfield = Strfield + "[" + Field + "]";
if (Confirm ("Add" + Field + "?"))
Document.sqlForm.strSQL.value = Strfield;
}
-->

</script>


<body bgcolor= "#f4e1d2" >

<%
If request ("CreateTable") <> "Create Table" Then
Response.Write ("<form name=" "Sqlform" "action=" "sqlultimate.asp" "method=" "POST" ">" & vbCrLf)
End If

If request ("createtable") = "Create Table" Then
Call CreateTable ()
ElseIf strserver = "" or Request ("showconnectdb") = "Connect" Then
%>

<p align=center>
Server: <input name= "SQL Server" type= "text" value= "<%= strserver%>" ><br>
User Name: <input name= "log_in" type= "text" value= "<%= struserid%>" ><br>
Password: <input name= "User_password" type= "Password" value= "<%= strpassword%>" ><br><br>
<input type=submit>
</p>
<%
ElseIf request ("savequery") = "Save Query" and strSQL <> "" Then
Call Savequery (Strsql,request ("Booltableinfo"))
Else
%>

Database is: <font color=purple><%= strDB%></font>
User is: <font color=purple><%= struserid%></font><table border= "0" cellspacing= "0" width= "100%" >
<tr>
&LT;TD valign=top bgcolor= #f0f3b1 width= "60%" ><b>sql query</b></td>


</td>
&LT;TD valign=top bgcolor= #cbf3bb width= "40%" ><b>work space</b>
</td>
</tr>
&LT;TR&GT;&LT;TD Bgcolor=black colspan=2>
<%
If strDB <> "" Then
Call Getidentity (Strserver,strdb,struserid, strpassword)
Call Tabledropdown (Strdb,struserid, strpassword)
%>

<select name=sqltype>
<option value= "Select" <%= strQOption1%>> select</option>
<option value= "Insert" <%= strQOption2%>> insert</option>
<option value= "Update" <%= strQOption3%>> update</option>
</select>

<input type=submit name= "createsqlstatement" value= "Create" >
<input type=submit name= "createtable" value= "Create tabl"



Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.