How to delete a table in database
S T E P - 1
- First, we will need a connection.
Dim oConn
Set oConn = Server.CreateObject("ADODB.Connection")
oConn.Open "Driver={Microsoft Access Driver (*.mdb)};DBQ=" & Server.MapPath("db1.mdb")
S T E P - 2
- We can use a SQL command to delete a table:
oConn.Execute "DROP TABLE Member" ' Delete a table call "Member"
S T E P - 3
- After using the connection, we will need to close it!
oConn.Close
Set oConn = Nothing
No comments:
Post a Comment