Article View: borland.public.cppbuilder.database.ado
Article #2809Re: How to Query in files
From: Viatcheslav V. Vassiliev
Date: Sat, 22 Mar 2003 13:27
Date: Sat, 22 Mar 2003 13:27
38 lines
2190 bytes
2190 bytes
AQNormal->Filtered = false;
AQNormal->Filter = "Age > 20";
AQNormal->Filtered = true;
----------------------------------------------------------------
Regards,
Viatcheslav V. Vassiliev
http://www.oledbdirect.com
The fastest way to access MS SQL Server, MS Jet (MS Access)
and Interbase (through OLEDB) databases.
"HuangC" <akeehuang@163.net> �������/�������� � �������� ���������:
news:3e7c223d@newsgroups.borland.com...
> Hi all, I have selected some records and backup it to file,
> now i load it to a dataset,
> but how can query this dataset, the following is my code:
> Save:
> TADOQuery *AQNormal;
> ...
> // the connected is correct
> AQNormal->Close();
> AQNormal->SQL->Clear();
> // Select all the record that age is more than 20
> // the Age is a field of my access database
> AQNormal->SQL->Add("Select * form mytable where Age > 20");
> AQNormal->Open();
> AQNormal->SaveToFile("C:\\temp.dat");
> ...
>
> Read:
> AQNormal->LoadFromFile("C:\\temp.dat");
> // now I want query the record that age is more than 50
> // How can i do?
> // Any hint? TIA!
>
> Sky
>
>
Technical Details
Message-ID:
<3e7c64a5@newsgroups.borland.com>Path:
arc1-ca.pugleaf.net!archiver1.google.com!news1.google.com!sn-xit-02!sn-xit-03!sn-xit-01!sn-xit-08!supernews.com!64.152.100.70.MISMATCH!sjc70.webusenet.com!c03.atl99!news.webusenet.com!news02.tsnz.net!newsfeed01.tsnz.net!newsfeeds.ihug.co.nz!ihug.co.nz!newsgroups.borland.com!not-for-mailReferences:
<3e7c223d@newsgroups.borland.com>Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII X-Google-Thread: 10698b,a73292e9d8e21483 X-Google-Attributes: gid10698b,public X-Google-ArrivalTime: 2003-03-22 05:28:24 PST From: "Viatcheslav V. Vassiliev" <support@oledbdirect.com> Newsgroups: borland.public.cppbuilder.database.ado References: <3e7c223d@newsgroups.borland.com> Subject: Re: How to Query in files Date: Sat, 22 Mar 2003 16:27:00 +0300 Lines: 40 X-Priority: 3 X-MSMail-Priority: Normal X-Newsreader: Microsoft Outlook Express 6.00.2800.1106 X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1106 NNTP-Posting-Host: 213.247.201.57 Message-ID: <3e7c64a5@newsgroups.borland.com> X-Trace: newsgroups.borland.com 1048339621 213.247.201.57 (22 Mar 2003 05:27:01 -0800) Path: arc1-ca.pugleaf.net!archiver1.google.com!news1.google.com!sn-xit-02!sn-xit-03!sn-xit-01!sn-xit-08!supernews.com!64.152.100.70.MISMATCH!sjc70.webusenet.com!c03.atl99!news.webusenet.com!news02.tsnz.net!newsfeed01.tsnz.net!newsfeeds.ihug.co.nz!ihug.co.nz!newsgroups.borland.com!not-for-mail