Article View: comp.lang.pascal.delphi.databases
Article #172Re: SQL-Queries
From: Branko Starasinic
Date: Mon, 20 Oct 1997 00:00
Date: Mon, 20 Oct 1997 00:00
58 lines
3067 bytes
3067 bytes
On Mon, 20 Oct 1997 09:40:47 GMT, "Roger Beardsworth" <roger.beardsworth@dai.nospam.co.uk> wrote: >1. You could change your server sort-order to case-insensitive. However, >this requires rebuilding the database and all the data within it. And you >can't use normal backup and restore. >Alternatively, you could convert both field name and constant to uppercase >- but that probably will negatively affect performance if an index could be >used. >2. Not unless you have an IDENTITY column (or similar) in the table. >Relational database tables are not supposed to be ordered in any way. >3. I would recommend SQL Server Books Online (comes with the setup CD), as >it has a decent search engine. > >Regards, Roger. > >Heinz A. Krebs Dipl.-Ing. <hkrebs@fbch.tuwien.ac.at> wrote in article ><344B1EAD.E25@fbch.tuwien.ac.at>... >> servas! >> >> i have three small questions about sql-queries: >> >> 1. how can i make a case-insensitive selection? if i make the following: >> SELECT titel FROM database WHERE titel LIKE '%apple%' >> i don't get the entries with 'Apple', but i want them all! Try SELECT titel FROM database WHERE UPPER(titel) LIKE '%APPLE%' >> >> 2. can i retrieve a record by his recordnumber like >> SELECT titel, rezept FROM database WHERE recordnumber=4162 >> >> 3. where can i get a good explanation of SQL-statements on the web to >> avoid further boring questions by me? ;-) >> >> >> ciao >> H. >> >> *********************************************************************** >> KOS - Kochbuch Online System >> >> 45000 Kochrezepte online siehe unter http://www.styria.co.at/kos/ >> *********************************************************************** >> Heinz A. Krebs Dipl.Ing. voice: 43-1-4077234 or 43-1-58801-5011 >> Vienna University fax: 43-1-4077235 >> of Technology email: hkrebs@fbch.tuwien.ac.at >> Institute of Organic Chemistry WWW: http://info.tuwien.ac.at/ >> Department Naturstoffsynthese orgchem/krebs/ >> Getreidemarkt 9/9/154 fido: 2:310/67 >> A - 1060 Wien mailbox: 43-1-4077235 >> *********************************************************************** >>
Technical Details
Message-ID:
<344b525a.22883307@forums.borland.com>Path:
arc1-ca.pugleaf.net!unknown!not-for-mailReferences:
<344B1EAD.E25@fbch.tuwien.ac.at> <01bcdd3c$92eca5d0$9f0000d0@pccas2>Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: ffff5,c6b02df51994e2b0 X-Google-Attributes: gidffff5,public X-Google-Thread: 11301e,c6b02df51994e2b0 X-Google-Attributes: gid11301e,public X-Google-Thread: 10de66,c6b02df51994e2b0 X-Google-Attributes: gid10de66,public From: branko.starasinic@danfoss-cmpr.si (Branko Starasinic) Subject: Re: SQL-Queries Date: 1997/10/20 Message-ID: <344b525a.22883307@forums.borland.com> X-Deja-AN: 281975648 References: <344B1EAD.E25@fbch.tuwien.ac.at> <01bcdd3c$92eca5d0$9f0000d0@pccas2> Organization: None Newsgroups: comp.lang.pascal.delphi.databases,borland.public.delphi.database.sqlservers,microsoft.public.sqlserver.programming