Autor Beitrag
der Berliner
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starontopic star
Beiträge: 417

Win Xp Home
delphi 2005
BeitragVerfasst: Mo 18.09.06 17:04 
Hi all
wie Schreibt man das hier richtig ?

ausblenden Delphi-Quelltext
1:
Query_Vorgang.SQL.Text:='SELECT AKS FROM Vorgangsnummern WHERE Copy(Query_Vorgang.FieldByName("AKS").AsString,5,1)Like "0"';					


Danke im vorraus
Gruß

_________________
[b]Ich weiß nicht immer, wovon ich rede. Aber ich weiß, dass ich recht habe.[b]
mkinzler
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starofftopic star
Beiträge: 4106
Erhaltene Danke: 13


Delphi 2010 Pro; Delphi.Prism 2011 pro
BeitragVerfasst: Mo 18.09.06 17:20 
So garnicht. Du brauchst eine SQ:Funktion die dir einen Teilstring zurückliefert. Z.B. substring.
Welche Datemnbank?

_________________
Markus Kinzler.
der Berliner Threadstarter
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starontopic star
Beiträge: 417

Win Xp Home
delphi 2005
BeitragVerfasst: Mo 18.09.06 17:23 
Access

ich möchte nur die Aks-Nummern deren 5 Stelle eine 0 ist.
gruß

_________________
[b]Ich weiß nicht immer, wovon ich rede. Aber ich weiß, dass ich recht habe.[b]
Grenzgaenger
Ehemaliges Mitglied
Erhaltene Danke: 1



BeitragVerfasst: Mo 18.09.06 17:29 
ausblenden Delphi-Quelltext
1:
... like "_____0%					


5 Zeichen egal = _, nächste stelle eine 0 und der rest ist egal %

schau mal unter like und wildcards. <HTH>
mkinzler
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starofftopic star
Beiträge: 4106
Erhaltene Danke: 13


Delphi 2010 Pro; Delphi.Prism 2011 pro
BeitragVerfasst: Mo 18.09.06 17:32 
Schau mal ob Access die Funktion substring() oder ähnlich besitzt.
[Edit: Google meint MID() in Access]

_________________
Markus Kinzler.
der Berliner Threadstarter
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starontopic star
Beiträge: 417

Win Xp Home
delphi 2005
BeitragVerfasst: Mo 18.09.06 17:35 
@Grenzgaenger: Danke das Funktioniert so wie ich will. :D

@MKinzler: Auch Danke mit Substring werde ich mich mal beschäftigen.

Gruß

_________________
[b]Ich weiß nicht immer, wovon ich rede. Aber ich weiß, dass ich recht habe.[b]