Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Searching table without changing recno?
Message
From
16/03/1998 04:59:25
Cetin Basoz
Engineerica Inc.
Izmir, Turkey
 
 
To
15/03/1998 03:01:22
Dragan Nedeljkovich (Online)
Now officially retired
Zrenjanin, Serbia
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
00084382
Message ID:
00084773
Views:
35
>>>Can anyone tell me how to search table without moving a record pointer?
>>>I have table in record buffering mode. I'm adding a new record and I want check some field contents before 'tableupdate'-ing.
>>>I used KEYMATCH function but when I called it, validation rules for the record activated. It seems to me that KEYMATCH is changing a recno of the searched table.
>>Use again and sql are good for not moving the pointer but what if you want to check a buffered record too (BTW keymatch is worst for me)?
>>You should use the buffered table - go check and return. Problem is firing valid events. For that I first check the current record, save contents to an object var, fill with values that are valid (and dummy placeholders), do my check, return to the record and restore contents from saved obj var.
>>Cetin
>
>Now this is not clear to me - I've had just the oposite trouble:
>- enter a value into a field (bound control)
>- its valid method wants to know if this key exists, so it selects another alias of the table
>- it finds the buffered record there.
>Buffering, I'm not sure (for both aliases), should be 3 or 5.

Dragan are you sure buffering is 5 or 3 (with no rec pointer movement) ?
* Customer in DE
use customer in 0 again alias customer1    && Customer is buffered
=seek(ThisForm.txtCust_id.value,"customer1","cust_id")
select customer1
brow                  && No changed or added record
tableupdate(2,.t.,"customer")
brow                  && Changed or added here
Cetin
Çetin Basöz

The way to Go
Flutter - For mobile, web and desktop.
World's most advanced open source relational database.
.Net for foxheads - Blog (main)
FoxSharp - Blog (mirror)
Welcome to FoxyClasses

LinqPad - C#,VB,F#,SQL,eSQL ... scratchpad
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform