🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: pl.comp.lang.delphi.bazy-danych
Article #70657

Re: Aktywna pozycja tabeli po zatwierdzeniu zmian

#70657
From: Rajmund Wrotek
Date: Thu, 23 Aug 2007 08:13
27 lines
1908 bytes
Użytkownik "Tygrys" <news15@wywalto.tygrys.com.pl> napisał w wiadomości 
news:fajeh8$4am$2@nemesis.news.tpi.pl...
> Art pisze:
>>
>> A co w sytuacji gdy chcę po DM.IBTransaction1.Commit lub CommitRetaining
>> zrobić selecta? Wtedy też aktywny staje się piwerszy wiersz tabeli :(
>>
>>   DM.DSetDokument.SelectSQL.Clear;
>>   DM.DSetDokument.SelectSQL.Add('select *  from DOKUMENT');
>>   DM.DSetDokument.SelectSQL.Add('where upper(NAZWA_DOKUMENTU)
>>     Like :NAZWA_DOKUMENTU');
>>
>>   DM.DSetDokument.ParamByName('NAZWA_DOKUMENTU').AsString
>>     := '%'+AnsiUpperCase(Edit1.Text)+'%';
>>
>>   DM.DSetDokument.Open;
>>
>>
>> a ja bym chciał ten, który wcześniej edytowałem.
>
> A jaką masz gwarancję że ten selekt będzie zawierał ten ostatnio dodany 
> rekord?
>
> Tygrys

czyli pozostaje ci locate :-) i liczyć na to, że select niczego nie zmieni 
Technical Details
Message-ID: <46cd3d4c$0$511$f69f905@mamut2.aster.pl>
Path: mbox-mo1.pugleaf.net!news-archive.icm.edu.pl!newsfeed.gazeta.pl!news.astercity.net!news.aster.pl!not-for-mail
References: <faggof$esp$1@nemesis.news.tpi.pl> <fahalp$hkp$1@atlantis.news.tpi.pl> <fahdgr$ktp$1@nemesis.news.tpi.pl> <46cc4d36$0$519$f69f905@mamut2.aster.pl> <fahphr$30d$1@nemesis.news.tpi.pl> <fajeh8$4am$2@nemesis.news.tpi.pl>

Show Full Headers
Complete Article Headers
Path: mbox-mo1.pugleaf.net!news-archive.icm.edu.pl!newsfeed.gazeta.pl!news.astercity.net!news.aster.pl!not-for-mail
From: "Rajmund Wrotek" <rajmund.wrotek@interia.pl>
Newsgroups: pl.comp.lang.delphi.bazy-danych
References: <faggof$esp$1@nemesis.news.tpi.pl> <fahalp$hkp$1@atlantis.news.tpi.pl> <fahdgr$ktp$1@nemesis.news.tpi.pl> <46cc4d36$0$519$f69f905@mamut2.aster.pl> <fahphr$30d$1@nemesis.news.tpi.pl> <fajeh8$4am$2@nemesis.news.tpi.pl>
Subject: Re: Aktywna pozycja tabeli po zatwierdzeniu zmian
Date: Thu, 23 Aug 2007 10:13:05 +0200
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2900.3138
X-RFC2646: Format=Flowed; Response
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.3138
Lines: 29
Message-ID: <46cd3d4c$0$511$f69f905@mamut2.aster.pl>
NNTP-Posting-Date: 23 Aug 2007 07:54:52 GMT
NNTP-Posting-Host: 212.76.47.8
X-Trace: 1187855692 mamut2.aster.pl 511 212.76.47.8:61264
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit