Article View: borland.public.jbuilder.database
Article #217Re: QueryDataSet: How to do "trial" query and accept or decline
From: Mehmet F. Erten
Date: Wed, 19 Jul 2006 14:01
Date: Wed, 19 Jul 2006 14:01
29 lines
2216 bytes
2216 bytes
Hi,
Try this.
hasmap or treemap myMap
myMap.put("OLD", currentQueryDataSet)
currentQueryDataSet = new QueryDataSet(with the new Query String).
If you don't like it. (if getRowCouunts == 0)
currentQueryDataSet = (QueryDataSet) myMap.get("OLD");
"John T. Dow" <jo
hn@johntdow.com> wrote in message
news:Xns98053677CC68Cjohnjohntdowcom@207.105.83.66...
> Is it possible to change a querydataset's query string and execute the
> query, and then revert to the original query string with the original rows
> and cursor position without having to reexecute with the original query
> string?
>
> I have an application where the user can easily create new queries on the
> fly. As I have developed it so far, if the user tries a new query, he
> loses
> the old. I would like to be able to revert to the old query, for example
> if
> the new query fails to find any rows.
>
> Is it possible to do something clever like saving the original
> QueryProvider? Can you clone the entire qds, change the query string etc,
> and then if you like the outcome substitute the new qds for the old?
>
> John
Technical Details
Message-ID:
<44be3b53$1@newsgroups.borland.com>Path:
arc1-ca.pugleaf.net!g2news2.google.com!news3.google.com!border1.nntp.dca.giganews.com!nntp.giganews.com!nx01.iad01.newshosting.com!newshosting.com!news-out.nntp.be!sp6iad.superfeed.net!in1.nntp.be!caladan.landsraad.net!newsgroups.borland.com!not-for-mailReferences:
<Xns98053677CC68Cjohnjohntdowcom@207.105.83.66>Show Full Headers
Complete Article Headers
X-Google-Thread: 1073da,3b0213ebece65c18 X-Google-Attributes: gid1073da,public X-Google-Language: ENGLISH,ASCII-7-bit Subject: Re: QueryDataSet: How to do "trial" query and accept or decline From: "Mehmet F. Erten" <mehmet_erten@mblsoft.com> Date: Wed, 19 Jul 2006 10:01:52 -0400 Message-ID: <44be3b53$1@newsgroups.borland.com> References: <Xns98053677CC68Cjohnjohntdowcom@207.105.83.66> Lines: 31 NNTP-Posting-Host: 70.90.110.46 Organization: MBL Systems, Inc Path: arc1-ca.pugleaf.net!g2news2.google.com!news3.google.com!border1.nntp.dca.giganews.com!nntp.giganews.com!nx01.iad01.newshosting.com!newshosting.com!news-out.nntp.be!sp6iad.superfeed.net!in1.nntp.be!caladan.landsraad.net!newsgroups.borland.com!not-for-mail Newsgroups: borland.public.jbuilder.database X-Trace: newsgroups.borland.com 1153317715 70.90.110.46 (19 Jul 2006 07:01:55 -0700) Reply-to: "Mehmet F. Erten" <mehmet_erten@mblsoft.com> X-Priority: 3 X-MSMail-Priority: Normal X-Newsreader: Microsoft Outlook Express 6.00.2900.2869 X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.2869 X-RFC2646: Format=Flowed; Original