Click here to Skip to main content
Click here to Skip to main content
Articles » Database » Database » General » Downloads
 
Add your own
alternative version

Online DB Administration

, 17 Mar 2003
Online administration of your database. Create or modify tables, keys, and indexes. Edit or insert data.
// JavaScript source code

function DropTable(sTable) {
	if(!confirm('Drop table ' + sTable + '?')) return;
	document.all.cmdfrm.src = 'nycmd.asp?c=11&table='+sTable;
}

function TruncateTable(sTable) {
	if(!confirm('Truncate table ' + sTable + '?')) return;
	document.all.cmdfrm.src = 'nycmd.asp?c=12&table='+sTable;
}

function DropView(sTable) {
	if(!confirm('Drop view ' + sTable + '?')) return;
	document.all.cmdfrm.src = 'nycmd.asp?c=16&table='+sTable;
}

function TruncateView(sTable) {
	if(!confirm('Truncate view ' + sTable + '?')) return;
	document.all.cmdfrm.src = 'nycmd.asp?c=12&table='+sTable;
}

function DropIndex(sTable,sIndex) {
	if(!confirm('Drop index ' + sTable + '.' + sIndex + '?')) return;
	document.all.cmdfrm.src = 'nycmd.asp?c=13&table='+sTable+'&index='+sIndex;
}

function DropKey(sTable,sKey) {
	if(!confirm('Drop key ' + sTable + '.' + sKey + '?')) return;
	document.all.cmdfrm.src = 'nycmd.asp?c=14&table='+sTable+'&key='+sKey;
}

function DropColumn(sTable,sColumn) {
	if(!confirm('Drop column ' + sTable + '.' + sColumn + '?')) return;
	document.all.cmdfrm.src = 'nycmd.asp?c=15&table='+sTable+'&column='+sColumn;
}

var g_sError;

function body_onload() {
	if(''+g_sError!='undefined')
		alert(g_sError);
}

function SetErrorMessage(sError) {
	if(''+g_sError!='undefined') 
		g_sError += '\n\n' + sError;
	else
		g_sError = sError;
}

By viewing downloads associated with this article you agree to the Terms of Service and the article's licence.

If a file you wish to view isn't highlighted, and is a text file (not binary), please let us know and we'll add colourisation support for it.

License

This article has no explicit license attached to it but may contain usage terms in the article text or the download files themselves. If in doubt please contact the author via the discussion board below.

A list of licenses authors might use can be found here

Share

About the Author

Bjornar Henden
Web Developer
Norway Norway
No Biography provided

| Advertise | Privacy | Mobile
Web01 | 2.8.141022.2 | Last Updated 18 Mar 2003
Article Copyright 2002 by Bjornar Henden
Everything else Copyright © CodeProject, 1999-2014
Terms of Service
Layout: fixed | fluid