Autor Beitrag
biohazard
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starontopic star
Beiträge: 89



BeitragVerfasst: Fr 05.09.03 13:06 
Hallo,

Ich möchte während der Laufzeit eine MySQL Datenbank anlegen. Für den Zugriff benutze ich ZEOS.

Und so versuch ich es:
ausblenden Delphi-Quelltext
1:
2:
3:
4:
5:
dbMySQL.Database:= edt_db.Text; 
dbMySQL.Host:=edt_Server.Text;
dbMySQL.Login:=edt_Login.Text;  
dbMySQL.Password:=edt_Passwort.Text; 
dbMySQL.CreateDatabase('Name');

Leider will das nicht funktionieren. Kann mir da jemand helfen. Die Fehlermeldung "Database creating error" hilft mir da auch nicht wirklich.

_________________
LIVE FAST, DIE YOUNG
UC-Chewie
ontopic starontopic starontopic starontopic starontopic starontopic starofftopic starofftopic star
Beiträge: 531

WinXP
D5 Ent
BeitragVerfasst: Fr 05.09.03 13:43 
Vielleicht hat der Benutzer nicht die Rechte, Datenbanken zu erstellen.

_________________
Egal wie dumm man selbst ist, es gibt immer andere, die noch dümmer sind
biohazard Threadstarter
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starontopic star
Beiträge: 89



BeitragVerfasst: Fr 05.09.03 14:03 
Gibt es eine Möglichkeit das vorher zu prüfen?

Eigentlich ist das nur eine Testdatenbank und da hab ich eigentlich keine großartigen Rechte vergeben. Tabellen erstellen und löschen geht ja auch.

Was ich nicht ganz verstehe ist:
Bei Database wird beim normalen Zugriff die Datenbank angegeben.
Was muß dann beim erstellen rein? Bei CreateDatabase gebe ich doch erst denn Namen der DB an.

_________________
LIVE FAST, DIE YOUNG
neojones
ontopic starontopic starontopic starontopic starontopic starhalf ontopic starofftopic starofftopic star
Beiträge: 1206
Erhaltene Danke: 1



BeitragVerfasst: Fr 05.09.03 16:08 
Warum führst Du nicht direkt den entsprechenden Befehl aus?

CREATE DATABASE name

?

_________________
Ha! Es compiliert! Wir können ausliefern!