Article View: borland.public.vdbase.data.sql
Article #905Re: Filter on a Value
From: Tom Preston
Date: Sat, 27 Jun 1998 00:00
Date: Sat, 27 Jun 1998 00:00
52 lines
2089 bytes
2089 bytes
Romain . . . A few points . . . 1: TCUSNUM is a numeric (7) field in the rowset representing the customer number in the transaction table 2: form.combobox1 is datasourced to form.cusscr1.rowset.fields["COMPANY"] ; a chr (20) field that represents the company name in the customer master table 3: form.cusnum_holder is datalinked to form.cusscr1.rowset.fields["CCUSNUM"]; a num (7) field that represents the customer number in the customer master table 5: the 'onchange' event of the combobox has an applylocate() that moves the record pointer to the appropriate row in the rowsetset (finding the first match of the company name) 6: after the applylocate(), I want to filter the rowset to show only those transactions for the currently selected company When I use the syntax . . . form.rowset.filter=[tcusnum=']+(form.cusnum_holder.value)+['] I get the error message . . . "Database Engine Error: Operation not applicable." I have tried many (sometimes weird) variations of the above syntax; to no avail. Any further help you could provide would be warmly welcomed. Thanks, Tom Preston On Sat, 27 Jun 1998 13:05:47 +0200, Romain@Do.not.reply.via.e-mail (Romain Strieff [TeamB]) wrote: >In article <359470a5.45211047@forums.borland.com>, tgp@compuserve.com >grudgingly admits... >The filter property is a string, not a command, just build it with >whatever you have. > > n=1 > filter = [tcusnum=]+ltrim(str(n)) >or > > filter = [Name=']+trim(form.entryfield1.value)+['] >-- >Romain Strieff [TeamB]
Technical Details
Message-ID:
<359518f5.40480547@forums.borland.com>Path:
arc1-ca.pugleaf.net!unknown!not-for-mailReferences:
<359470a5.45211047@forums.borland.com> <MPG.ffef07793c29ed698aeb7@forums.borland.com>Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: ff5a1,9cc7a67ae9405e2d X-Google-Attributes: gidff5a1,public From: tgp@compuserve.com (Tom Preston) Subject: Re: Filter on a Value Date: 1998/06/27 Message-ID: <359518f5.40480547@forums.borland.com> X-Deja-AN: 366627307 References: <359470a5.45211047@forums.borland.com> <MPG.ffef07793c29ed698aeb7@forums.borland.com> Organization: Another Netscape Collabra Server User Newsgroups: borland.public.vdbase.data.sql