grahamb Posted November 2, 2004 Posted November 2, 2004 I'm trying to export a file from our FileMaker-based POS to send to the University's PeopleSoft finance system. One of the requirements is "a sequential number starting with 1 for the first line and incremented by 1 for each subsequent line" -- i.e. a line number. This wouldn't be a serial number stored within the record (each record already has one) but would be within the found set (the first found record is 1, the second in the found set is 2, etc). Is there a way to do this? I looked at the status functions and couldn't see anything that looked like it would work. I could write a script that would loop through each record, setting a numeric field to the value of the previous record's field + 1, but I'd like to do something cleaner if possible.
Fenton Posted November 2, 2004 Posted November 2, 2004 You could create an UNSTORED calculation field, Status(CurrentRecordNumber), then export that. It would of course only be the same for that particular found set. So what happens next time you export, and the records start with 1 again? I can't imagine that's what they want; but I don't know. If they want a "unique" sequential number, that's a different thing. You could do it with a loop; but you'd have to go check what the last export ended with. Tip for loops: View as Form, much faster.
grahamb Posted November 2, 2004 Author Posted November 2, 2004 Brilliant! That worked perfectly. I had actually tried Status(CurrentRecordNumber) earlier but had forgotten to make it unstored.
Recommended Posts
This topic is 7326 days old. Please don't post here. Open a new topic instead.
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now