Click here to Skip to main content
15,915,501 members
Home / Discussions / Database
   

Database

 
QuestionProblem with SET and SELECT (to assign a local variable) Pin
dlarkin7713-May-10 4:52
dlarkin7713-May-10 4:52 
AnswerRe: Problem with SET and SELECT (to assign a local variable) Pin
Corporal Agarn13-May-10 6:20
professionalCorporal Agarn13-May-10 6:20 
GeneralRe: Problem with SET and SELECT (to assign a local variable) Pin
dlarkin7713-May-10 6:22
dlarkin7713-May-10 6:22 
Questioncreate database, which parameter Pin
luccingolo13-May-10 2:52
luccingolo13-May-10 2:52 
AnswerRe: create database, which parameter Pin
Corporal Agarn13-May-10 4:09
professionalCorporal Agarn13-May-10 4:09 
GeneralRe: create database, which parameter Pin
luccingolo13-May-10 5:57
luccingolo13-May-10 5:57 
GeneralRe: create database, which parameter Pin
Corporal Agarn13-May-10 6:17
professionalCorporal Agarn13-May-10 6:17 
GeneralRe: create database, which parameter Pin
luccingolo13-May-10 6:53
luccingolo13-May-10 6:53 
Sorry, still get an error.
Maybe i misundertood you.
Fact is that i still get an error.

What i did is using your sql-command as string for my SQL-command.
What I mean is this:
In the Form1_Load-Event of my Application(project).

MyConnection = "Server=localhost;" & "DataBase=;" & "Integrated Security=SSPI"
'Your line of code
Dim mySQL As String = "IF EXISTS (SELECT name FROM sys.databases WHERE name = N'MyDatabase')DROP DATABASE [MyDatabase]"

Try
Dim conn As New SqlConnection(MyConnection)
Dim myCmd As New SqlCommand(mySQL, conn)

conn.Open()
myCmd.ExecuteNonQuery()
conn.Close()
.
.
.
Last but not least, don't forget that the point is not only to "drop" a Database but i'm trying so hard to create a SQL-Database. Smile | :)
thank you,
Lucchingolo
GeneralRe: create database, which parameter Pin
Corporal Agarn13-May-10 7:01
professionalCorporal Agarn13-May-10 7:01 
GeneralRe: create database, which parameter Pin
luccingolo13-May-10 7:14
luccingolo13-May-10 7:14 
QuestionWPF cascaded combo Pin
bindum3112-May-10 20:08
bindum3112-May-10 20:08 
AnswerRe: WPF cascaded combo Pin
Michael J. Eber13-May-10 10:39
Michael J. Eber13-May-10 10:39 
AnswerRe: WPF cascaded combo Pin
Michael J. Eber13-May-10 12:07
Michael J. Eber13-May-10 12:07 
Questionhow to write the querry for copying one image field into another image field in sql server 2000 Pin
developerit12-May-10 20:04
developerit12-May-10 20:04 
AnswerRe: how to write the querry for copying one image field into another image field in sql server 2000 Pin
developerit14-May-10 22:28
developerit14-May-10 22:28 
QuestionOS dependency with Interbase database 6.0 driver? Pin
navneet.professional12-May-10 19:57
navneet.professional12-May-10 19:57 
AnswerRe: OS dependency with Interbase database 6.0 driver? Pin
Henry Minute13-May-10 1:48
Henry Minute13-May-10 1:48 
QuestionHow to use CLongBinary to store image of size > 64 KB with Interbase Database 6.0 driver Pin
navneet.professional12-May-10 19:50
navneet.professional12-May-10 19:50 
QuestionNot Equal to Question/Problem Pin
djhankypark12-May-10 6:09
djhankypark12-May-10 6:09 
AnswerRe: Not Equal to Question/Problem Pin
J4amieC12-May-10 6:23
J4amieC12-May-10 6:23 
AnswerRe: Not Equal to Question/Problem Pin
David Skelly12-May-10 6:24
David Skelly12-May-10 6:24 
GeneralRe: Not Equal to Question/Problem Pin
PIEBALDconsult12-May-10 18:21
mvePIEBALDconsult12-May-10 18:21 
AnswerRe: Not Equal to Question/Problem Pin
Chris Meech12-May-10 6:38
Chris Meech12-May-10 6:38 
GeneralRe: Not Equal to Question/Problem Pin
J4amieC12-May-10 21:49
J4amieC12-May-10 21:49 
QuestionNeed help in query Pin
Saiyed Alam12-May-10 2:48
Saiyed Alam12-May-10 2:48 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.