![]() | |
![]() |
| | Thread Tools | Display Modes |
#1
| |||
| |||
|
#2
| |||
| |||
|
|
I have a transaction table with 50K records in it There is a field called "period" (YYMM) which is the billing period this record belongs to. I want to locate the record before the first record in a given period. I perform a find on the desired period (ex period = "1001") which returns 43 records which I sort (by TransactionDate) then go to the first record. I set a variable to that RecordID number (in this example 36873). Then I extend the found set by setting the period to "" and perform the find. This returns 385 records and the record pointer moves automatically to the first record in the new found set. After sorting the records again I wanted to be able to move the record pointer back to my RecordID but 36873 is beyond the scope of the currently found set of 385. Shouldn't this be easier than this? |
)
#3
| |||
| |||
|
|
"GSteven" <GSP@DavClaServ> wrote in message news:1412d$4b5e42fc$d1a8fa82$16562 (AT) EDELTACOM (DOT) COM... I have a transaction table with 50K records in it There is a field called "period" (YYMM) which is the billing period this record belongs to. I want to locate the record before the first record in a given period. I perform a find on the desired period (ex period = "1001") which returns 43 records which I sort (by TransactionDate) then go to the first record. I set a variable to that RecordID number (in this example 36873). Then I extend the found set by setting the period to "" and perform the find. This returns 385 records and the record pointer moves automatically to the first record in the new found set. After sorting the records again I wanted to be able to move the record pointer back to my RecordID but 36873 is beyond the scope of the currently found set of 385. Shouldn't this be easier than this? RecordID is an internal serial number given to each record, but unless something has changed in newer versions of FileMaker (I had a very quick look in FileMaker 9, but may have missed it)you can't actually "go to" that record. The Script command Go To Record[Num] will go to record in position Num within the current Found Set's Sort Order, not the record with the RecordID of Num. To "move the record pointer" you would have to perform a looping Script to work through each record until it finds that same RecordID or reaches the end of the Found Set without finding it. e.g. Something like: Go To Record [First] Loop Exit Loop If [Get(RecordID) = g_StoredRecordID] Go To Record [Next, Exit After Last] End Loop If [Get(RecordID) <> g_StoredRecordID] Display ["Error: Record not in Found Set."] End If Helpful Harry ) |
#4
| |||
| |||
|
|
Thanks Harry, That's exactly what I wound up doing, even though it seems mighty labor intensive to have to shuffle through all records until I find the match. I hate to think of what happens when my 50K records becomes 500K? IMHO this (not having a function to go to a recordID number) looks like a major blunder on FMs behalf. Thanks again, Steve |
)
#5
| |||
| |||
|
|
Thanks Harry, That's exactly what I wound up doing, even though it seems mighty labor intensive to have to shuffle through all records until I find the match. I hate to think of what happens when my 50K records becomes 500K? IMHO this (not having a function to go to a recordID number) looks like a major blunder on FMs behalf. |
)![]() |
| Thread Tools | |
| Display Modes | |
| |