AGB  ·  Datenschutz  ·  Impressum  







Anmelden
Nützliche Links
Registrieren
Zurück Delphi-PRAXiS Programmierung allgemein Datenbanken Delphi TADOQuery Primary Key auslesen
Thema durchsuchen
Ansicht
Themen-Optionen

TADOQuery Primary Key auslesen

Ein Thema von Ducksoul · begonnen am 9. Feb 2010 · letzter Beitrag vom 21. Mär 2010
 
hoika

Registriert seit: 5. Jul 2006
Ort: Magdeburg
8.276 Beiträge
 
Delphi 10.4 Sydney
 
#6

Re: TADOQuery Primary Key auslesen

  Alt 10. Feb 2010, 13:15
Hallo,

Aus Google.

Zitat:
Using DAO you can look through the TableDef.Indexes collection. There is
an Index.Primary property that is true if the index is a primary key
index. You can then find the field names by looking at the fields
collection of the Index. There may be a more direct way using DAO that I
am not aware of.
Also

Delphi-Quellcode:
ADODataSet1.CommandText := 'SELECT * From Kunde';
        ADODataSet1.Active := True;
        ADODataSet1.IndexDefs.Update;

        for i:= 0 to ADODataSet1.IndexDefs.Count-1 do
        begin
          IndexDef:= ADODataSet1.IndexDefs[i]
          if IndexDef.Primary ...


Heiko
Heiko
  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 02:27 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 by Thomas Breitkreuz