August 27, 200223 yr I am trying to write a script that will find all records that do not have an empty start date field. Is there a special character or function that I can use to indicate not empty or null and be able to use it as a find criteria? I want the records that have an entry for a particular start date to show up on a specific layout. I just can't remember how to do this. Thanks, John
August 27, 200223 yr Use a calc field to test if the start date is empty or has a value in it, then perform the find on the calc field. Calc: If(IsEmpty(start date),0,1) Then find all the 1's, these will have a value in the start date field.
August 27, 200223 yr Or you can find directly in the StartDate field by entering a "greater than" date, such as: >1/1/1901 Or pick a date earlier than any possible date in the field.
August 27, 200223 yr If you type "=" in the date field and check the Omit box, you will be returned the set of records with dates in the date field. If you're scripting this, it would be: Enter Find Mode [ ] Insert Calculated Result[DateField,"="] Omit Record/Request Perform Find [ ] For the Omit record step to work in a script, the Status Area must not be locked.
August 28, 200223 yr Author Thank you for all the great input guys! I was able to get this to work. I have another question now that I got this to work. I want to find all records that have a valid start date (which I have done) and do not have a flag field marked. What I did was to put in an archive flag so our users did not have to see all the records that were already finished. So my ultimate goal is to find all records with a start date and that are not flagged to be archived. I have tried this several different ways and cannot get it to keep out the flagged records. Any more ideas as to how I can accomplish this. Thanks for the help that you have given already. John
August 28, 200223 yr Assuming your flag field has a "Yes" in it when the flag is set and "No" when it is not set, modify the script I posted earlier to: Enter Find Mode [ ] Set Field [Flag,"No"] New Record/Request Insert Calculated Result[DateField,"="] Omit Record/Request Perform Find [ ]
August 28, 200223 yr Author Thank you once again! I knew that I was missing a step but I couldn't figure out what it was. Thanks! John
Create an account or sign in to comment