AGB  ·  Datenschutz  ·  Impressum  







Anmelden
Nützliche Links
Registrieren
Zurück Delphi-PRAXiS Programmierung allgemein Datenbanken Delphi Create Table mit Firebird und ZEOS, wie richtig machen
Thema durchsuchen
Ansicht
Themen-Optionen

Create Table mit Firebird und ZEOS, wie richtig machen

Ein Thema von Jens Hartmann · begonnen am 26. Jan 2010 · letzter Beitrag vom 11. Feb 2010
 
Benutzerbild von DeddyH
DeddyH

Registriert seit: 17. Sep 2006
Ort: Barchfeld
27.666 Beiträge
 
Delphi 12 Athens
 
#10

Re: Create Table mit Firebird und ZEOS, wie richtig machen

  Alt 26. Jan 2010, 13:19
Du musst aber auch bis zum Ende lesen
Zitat:
This is fine, but now it seems you need to create a special stored procedure for this. Well, we use another new feature: EXECUTE BLOCK to make it a single statement:

SET TERM !! ;
EXECUTE BLOCK AS BEGIN
if (not exists(select 1 from rdb$relations where rdb$relation_name = 'EMPLOYEE')) then
execute statement 'create table employee ( id integer );';
END!!
SET TERM ; !!


Those SET TERM statements are only needed if you work from an administration tool like isql or FlameRobin. If you run it from your application code, just send the EXECUTE BLOCK block as a single statement.
Detlef
"Ich habe Angst vor dem Tag, an dem die Technologie unsere menschlichen Interaktionen übertrumpft. Die Welt wird eine Generation von Idioten bekommen." (Albert Einstein)
Dieser Tag ist längst gekommen
  Mit Zitat antworten Zitat
 


Forumregeln

Es ist dir nicht erlaubt, neue Themen zu verfassen.
Es ist dir nicht erlaubt, auf Beiträge zu antworten.
Es ist dir nicht erlaubt, Anhänge hochzuladen.
Es ist dir nicht erlaubt, deine Beiträge zu bearbeiten.

BB-Code ist an.
Smileys sind an.
[IMG] Code ist an.
HTML-Code ist aus.
Trackbacks are an
Pingbacks are an
Refbacks are aus

Gehe zu:

Impressum · AGB · Datenschutz · Nach oben
Alle Zeitangaben in WEZ +1. Es ist jetzt 06:19 Uhr.
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
LinkBacks Enabled by vBSEO © 2011, Crawlability, Inc.
Delphi-PRAXiS (c) 2002 - 2023 by Daniel R. Wolf, 2024-2025 by Thomas Breitkreuz