|
|
Perform Find in Script
Hi
How can I optimize this Perform Find in a Script:
Find Record Database::Date [= //]
It returns all records, which Date lays on Todays Date (//).
However how can I change it, so that it returns all records between Todays
Date and 7 days before Todays Date?
Thanks
Daniel
|
|
0
|
|
|
|
Reply
|
D
|
7/6/2005 2:18:49 PM |
|
On Wed, 6 Jul 2005 16:18:49 +0200, D wrote:
> Hi
>
> How can I optimize this Perform Find in a Script:
>
> Find Record Database::Date [= //]
>
> It returns all records, which Date lays on Todays Date (//).
>
> However how can I change it, so that it returns all records between Todays
> Date and 7 days before Todays Date?
enter find mode
setfield Database::Date ( get(currentdate)-7 & ".." & get(currentdate))
perform find
(maybe it's not setfield, but paste result - one of both requires result
type date, while the other may return any text)
|
|
0
|
|
|
|
Reply
|
Martin
|
7/6/2005 2:28:39 PM
|
|
In article <slrndcnqkn.4j8.t-use@ID-685.user.individual.de>, Martin
Trautmann <t-use@gmx.net> wrote:
> On Wed, 6 Jul 2005 16:18:49 +0200, D wrote:
> > Hi
> >
> > How can I optimize this Perform Find in a Script:
> >
> > Find Record Database::Date [= //]
> >
> > It returns all records, which Date lays on Todays Date (//).
> >
> > However how can I change it, so that it returns all records between Todays
> > Date and 7 days before Todays Date?
>
> enter find mode
> setfield Database::Date ( get(currentdate)-7 & ".." & get(currentdate))
> perform find
>
> (maybe it's not setfield, but paste result - one of both requires result
> type date, while the other may return any text)
Unless it's been fixed in FileMaker 7 (FINALLY!), there's a bug in the
Set Field command which means you can't use it with dates or times that
require anything other than a single date. Instead you have to use the
Insert Calculated Result (or whatever FileMaker 7 calls it).
Insert Calculated Result [DateField,
Status(CurrentDate) - 7 & "..." &
Status(CurrentDate)]
"Status(CurrentDate)" needs to be replaced with "Get(CurrentDate)" in
FileMaker 7.
The only problem is that the field DateField must be on the current
layout when the script is run. :o\
Helpful Harry
Hopefully helping harassed humans happily handle handiwork hardships ;o)
|
|
0
|
|
|
|
Reply
|
Helpful
|
7/6/2005 9:04:00 PM
|
|
> Insert Calculated Result [DateField,
> Status(CurrentDate) - 7 & "..." &
> Status(CurrentDate)]
>
> "Status(CurrentDate)" needs to be replaced with "Get(CurrentDate)" in
> FileMaker 7.
>
Hi Harry
Thank you for your help!
It works perfectly.
/Daniel
|
|
0
|
|
|
|
Reply
|
D
|
7/7/2005 6:23:48 AM
|
|
|
3 Replies
308 Views
(page loaded in 0.074 seconds)
Similiar Articles: FM8 Script Variable - comp.databases.filemakerGulp! At last - script variables!! But am I right to be astonished that the calculation result fort script variablkes can only be text, so that for ... Find mode - compare two fields - comp.databases.filemaker ...> Two number fields - can I do a find where field 1 > field 2? Not a Find as such, but you could make a script like this: Loop If (field 1 > field 2) Go to record ... Find and Replace script, util, etc... - comp.databases.filemaker ...Does anyone have or know of info for doing a Global find and replace of all occurrences of a specific value. Perhaps a 3rd party utility. I am talki... Skip or interrupt startup script - comp.databases.filemaker ...Whoops! I put: Close Window [Current Window] as the first line of my startup script. Now, the file closes the moment I open it. How do I recover? I... Unable to run scripts in current working directory - comp.soft-sys ...After attempting to use addpath (added using the startup.m script) to consolidate some often-used functions under a directory structure, I find myself... Checking to see if a value exists - comp.databases.filemaker ...Is it possible to check if a field contains a certain value in any of the records in my database? A script in my database is assigning an email addr... Find NT disk size with script/bat file - comp.os.ms-windows.nt ...I am wondering is there is a way to write a .bat file that will tell me the size of every NT4 machine that I have. I realize I can do this by instal... Request for Help with Calculation - comp.databases.filemaker ...Back to Scriptmaker Add a go to layout script step after your Find Add an Enter Preview Mode step next <pause> that's it.. Run your script It's easier to do than ... Detecting last record in a found set in a script step? - comp ...On Tue, 21 Jun 2005 11:02:46 -0400 (EDT), Richard Kayton wrote: > I am not sure what you mean below where you exit on last. As far as I can > tell there is no ... Calculating the 1st Wednesday of each month - comp.databases ...Hi, all: I would like some advice on how to script a find for all records which were created after the 1st Wednesday of the current month. Of cours... Perform Find - Database Software | FileMakerSelect Specify find requests or click Specify to create and manage find requests. The requests you create are stored with the script step. Script Steps Introduced in FileMaker Pro 11 | FileMakerScript Steps Introduced in FileMaker Pro 11 What new script steps are available in FileMaker Pro 11? Answer ID: 7591 Last Updated: Sep 19, 2011 03:05 PM PDT 7/26/2012 3:19:21 PM
|
|
|
|
|
|
|
|
|