Autor Beitrag
Klaus D.
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starontopic star
Beiträge: 63



BeitragVerfasst: Di 06.12.05 20:12 
Hallo
Ich habe folgenden SQL String.
ausblenden volle Höhe SQL-Anweisung
1:
2:
3:
4:
5:
6:
7:
8:
9:
10:
11:
12:
13:
14:
15:
16:
17:
18:
19:
20:
21:
22:
23:
24:
25:
26:
27:
28:
29:
30:
31:
32:
33:
34:
35:
36:
37:
38:
39:
40:
41:
42:
43:
44:
45:
SELECT DA.id_daten
     , DA.titel
     , DA.filmlaenge
     , DA.isbn
     , DA.erstellt
     , DA.geaendert
     , DA.sid_Genre
     , DA.sid_Format
     , DA.sid_verliehen
     , DA.verliehen_Vorname
     , DA.verliehen_Name
     , DA.verliehen_PLZ
     , DA.verliehen_Ort
     , DA.verliehen_Tel
     , DA.verliehen_am
     , FA.id_format
     , FA.format
     , GR.id_genre
     , GR.genre
     , WG.name
     , WG.id_verliehen

FROM             tbl_daten DA

LEFT OUTER JOIN  tbl_format  FA
ON              (DA.sid_format=FA.id_Format)

LEFT OUTER JOIN  tbl_genre  GR
ON              (DA.sid_genre=GR.id_Genre)

LEFT OUTER JOIN  tbl_weg  WG
ON              (DA.sid_verliehen=WG.id_verliehen)




WHERE ((UPPER(DA.titel)             like :p1) OR
       (UPPER(DA.filmlaenge)        like :p1) OR
       (UPPER(DA.isbn)              like :p1) OR
       (UPPER(DA.verliehen_Vorname) like :p1) OR
       (UPPER(DA.verliehen_am)      like :p1) OR
       (UPPER(FA.format)            like :p1) OR
       (UPPER(GR.Genre)             like :p1))

order by DA.Titel ASC


Mein Problem ist, das "DA.verliehen am" als Date gespeichert ist.der Rest sind alles Stringfelder.
wie kann ich in meinem SQL-Sring dieses Feld in meine Suchfunktion einbeziehen?
smiegel
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic star
Beiträge: 992
Erhaltene Danke: 1

WIN 7
D7 Prof., C#, RAD XE Prof.
BeitragVerfasst: Mi 07.12.05 07:33 
Hallo,

welche DB? Welche Zugriffsform (ADO)?

_________________
Gruß Smiegel
Ich weiß, daß ich nichts weiß, aber ich weiß mehr als die, die nicht wissen, daß sie nichts wissen. (Sokrates)
Klaus D. Threadstarter
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starontopic star
Beiträge: 63



BeitragVerfasst: Mi 07.12.05 19:13 
Gruß
Es handelt sich um eine ADS Database.

Ich sammle die Daten mit einer Query aus den Tabellen ein.
Sprich SQL.
Danke Klaus
noidic
ontopic starontopic starontopic starontopic starontopic starontopic starofftopic starofftopic star
Beiträge: 851

Win 2000 Win XP Vista
D7 Ent, SharpDevelop 2.2
BeitragVerfasst: Do 08.12.05 08:04 
Die meisten Datenbanken haben Konvertierungsfunktionen ( Oracle z.B. TO_CHAR ) , am besten mal in der DB-Doku suchen.

_________________
Bravery calls my name in the sound of the wind in the night...