[FX.php List] Database table modification

Duncan, Blair Blair.Duncan at bbdo.ca
Wed May 12 10:06:17 MDT 2010


Just as a followup...

My hacky solution although a bit faster still takes an incredibly long time 10 seconds or so to process, which is far too long - just to determine if a table has been modified.

Here is where I am at:
I have a table with about 15,000 records, the table has about 80 fields 3/4 of which are unstored calcfields.
Accessed through a layout that contains a single autoentered modifiedtimestamp field.

I also have another table similar to the one above above.

In PHP, I call a preFindScript that goes to each layout, sorts on the modified timestamp field and goes the last record.
Comparing the timestamp and record count with a pre-recorded timestamp and record count enable me to determine if the table has been modified.
Sorting seems to take the time which I thought that since the field is indexed would be much quicker.

What I really need is a GetTableModifiedTimeStamp("TableName") function.






Blair Duncan | Variable Data Manager
SGL Communications | 2 Bloor St W, Suite 3100 Toronto ON M4W 3R6
T 416-413-7537 | C 416-845-3357 | F 416-972-5656



-Original Message-


Thanks for the replys guys, it looks like there is no easy solution.

All I really want is to avoid using any type of calculation field that cannot be indexed as they kill performance.

Its really hacky but I guess I'll have to resort to maintain a form of control table with fields for:
TableName, ModificationTimeStamp, RecordCount

This way, at the end of the lengthy process it will need to update the control table.
The next time the lengthy process is run, it can first check the control table to quickly determine if it needs to run or not.






Blair Duncan | Variable Data Manager
SGL Communications | 2 Bloor St W, Suite 3100 Toronto ON M4W 3R6
T 416-413-7537 | C 416-845-3357 | F 416-972-5656



-Original Message-



Thanks but that doesn't really help as it just returns the underlying files modification date not the individual tables.
I can get that using php.

And an auto-enter serial number does not change when a record has been deleted.






Blair Duncan | Variable Data Manager
SGL Communications | 2 Bloor St W, Suite 3100 Toronto ON M4W 3R6
T 416-413-7537 | C 416-845-3357 | F 416-972-5656



-Original Message-



Hi Blair

You might want to check out FMDiff ( http://fmdiff.com ).  One of the
things it reports back is the Modified Timestamp per file (although
I'm not sure if it can get that from files hosted in FMServer or only
files opened locally).  If the table you want to check is one of many
in a single file, then it won't give you a Mod. Timestamp per table,
but if you've got a field set to auto-enter serial numbers, then it
can report back changes in "RecordChanges" and in
"nextAutoEnterValue".  There's a free trial version.

HTH,
-Joel

~~~~~~~~~~~~~~~~~~~~~~~
Joel Shapiro
FileMaker Pro
database & web design
http://www.jsfmp.com
415-269-5055
~~~~~~~~~~~~~~~~~~~~~~~


On May 5, 2010, at 10:54 AM, Duncan, Blair wrote:

> The database itself has many relations with child and grandchild
> records.
> Change in data.
>
>
>
> Blair Duncan | Variable Data Manager
> SGL Communications | 2 Bloor St W, Suite 3100 Toronto ON M4W 3R6
> T 416-413-7537 | C 416-845-3357 | F 416-972-5656
>
>
> -Original Message-
>
>
>
>
> Are you looking for change in data? or the table definition itself?
>
> ggt
>
> 2010/5/5 Duncan, Blair <Blair.Duncan at bbdo.ca>:
> > Hello list,
> >
> > Is there any way to get a timestamp of the last modification of a
> table?
> > I'm trying to skip a couple lengthy script steps if no changes
> have been
> > made since the last time it was run.
> > Currently I sort on record modification and check the last record
> but If
> > records are removed...no modification timestamp.
> >
> >
> >
> > Blair Duncan | Variable Data Manager
> > SGL Communications | 2 Bloor St W, Suite 3100 Toronto ON M4W 3R6
> > T 416-413-7537 | C 416-845-3357 | F 416-972-5656
> >
> >
> >
> > Please consider the environment before printing this e-mail.
> >
> > This message and any attachments contain information, which may be
> > confidential or privileged. If you are not the intended recipient,
> please
> > refrain from any disclosure, copying, distribution or use of this
> > information. Please be aware that such actions are prohibited. If
> you have
> > received this transmission in error, kindly notify us by e-mail to
> > helpdesk at bbdo.com. We appreciate your cooperation.
> >
> >
> >
> >
> >
> > _______________________________________________
> > FX.php_List mailing list
> > FX.php_List at mail.iviking.org
> > http://www.iviking.org/mailman/listinfo/fx.php_list
> >
> >
> _______________________________________________
> FX.php_List mailing list
> FX.php_List at mail.iviking.org
> http://www.iviking.org/mailman/listinfo/fx.php_list
>
>
> -Original Message-
>
>
>
> Please consider the environment before printing this e-mail.
>
> This message and any attachments contain information, which may be
> confidential or privileged. If you are not the intended recipient,
> please refrain from any disclosure, copying, distribution or use of
> this information. Please be aware that such actions are prohibited.
> If you have received this transmission in error, kindly notify us by
> e-mail to helpdesk at bbdo.com. We appreciate your cooperation.
>
>
>
>
>
>
> _______________________________________________
> FX.php_List mailing list
> FX.php_List at mail.iviking.org
> http://www.iviking.org/mailman/listinfo/fx.php_list

_______________________________________________
FX.php_List mailing list
FX.php_List at mail.iviking.org
http://www.iviking.org/mailman/listinfo/fx.php_list


-Original Message-


Please consider the environment before printing this e-mail.

This message and any attachments contain information, which may be confidential or privileged. If you are not the intended recipient, please refrain from any disclosure, copying, distribution or use of this information. Please`be aware that such actions are prohibited. If you have received this transmission in error, kindly notify us by e-mail to helpdesk at bbdo.com <mailto:helpdesk at bbdo.com> . We appreciate your cooperation.







-Original Message-


Please consider the environment before printing this e-mail.

This message and any attachments contain information, which may be confidential or privileged. If you are not the intended recipient, please refrain from any disclosure, copying, distribution or use of this information. Please be aware that such actions are prohibited. If you have received this transmission in error, kindly notify us by e-mail to helpdesk at bbdo.com <mailto:helpdesk at bbdo.com> . We appreciate your cooperation.







-Original Message-


Please consider the environment before printing this e-mail.

This message and any attachments contain information, which may be confidential or privileged. If you are not the intended recipient, please refrain from any disclosure, copying, distribution or use of this information. Please be aware that such actions are prohibited. If you have received this transmission in error, kindly notify us by e-mail to helpdesk at bbdo.com<mailto:helpdesk at bbdo.com>. We appreciate your cooperation.




-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mail.iviking.org/pipermail/fx.php_list/attachments/20100512/7b01fc50/attachment.html


More information about the FX.php_List mailing list