cr-dev Posted March 6, 2007 Posted March 6, 2007 Hello. Can anyone describe how I can setup a script to find all records that contain data in one particular field? I do not want to retrieve records that do not have any data in a defined field (null) I think the "IsValid tablename:fieldname" function plays a role here but I am so brain dead on where to go from here. Thanks much!
LaRetta Posted March 6, 2007 Posted March 6, 2007 (edited) You might try searching using *. This works for text, number, date, timestamp and time fields. So script could be: Set Error Capture [ On ] Perform Find [ Restore: yourField ... and then type plain * in value and ADD ] If [ not Get ( FoundCount ) ] Show Custom Dialog [ OK ; "No records found." ] Else ... do whatever with found set End If Oh how rude of me! Welcome to FM Forums! If I didn't answer your question correctly just let me know. You know the field name, right? Your post indicates you do - so you can script searching that field through all records. Also, if no records found and if you have Set Error Capture [ On ] then you will end up with zero records. You can either 1) end with a Show All Records or 2) if you need to preserve a prior found set, you can play window switcheroo (open new window to search). Perform Find and if no records - close window (thus preserving your prior found set). If records found, switch the newly opened window to your original layout, close the Find window and rename your window to the old one - it works a treat! I'll shut up now until we know more about your requirements here. LaRetta Edited March 7, 2007 by Guest Added a bunch ;-)
cr-dev Posted March 7, 2007 Author Posted March 7, 2007 Hi LaRetta! Thanks for the assistance! I use to be a member of this forum but somehow, my account was removed.(More than likely, due from inactivity) I used FileMaker extensively at a previous job and was pretty active in it. Worked with FM 7 and FM Server 7 Advanced. Now I am at a different job and demonstrating to executive management here, the power and finesse of FileMaker. For the features, I cannot find any other database system that does what I need it to do, as quickly as what FM can deliver. The Field I am searching on is an 'update' field and your response, I can work with it. Makes sense. :)
cr-dev Posted March 9, 2007 Author Posted March 9, 2007 LaRetta, Thanks for the input! All works perfect!
Recommended Posts
This topic is 6526 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