genevieve charbon Posted July 28, 2006 Posted July 28, 2006 Hi, Filemaker inc. just insulted our intelligence and despissed our time by wrongly labelling the class "tables" as tables while it returns the Table occurence. how can I get just the tables ? I need just the tables. I've spent 5 hours to do a solution, and all was nice till that "bug" ruined it.
Søren Dyhr Posted July 28, 2006 Posted July 28, 2006 This isn't a justified harm, it's pure and simple prejudice! It has been told over and over that the RG isn't a ERD in all the documentation! It's only if you have been mislead by the K1 download from here you critique could have some bearing: http://www.filemakertrial.com/trk/ We can all misunderstand a metaphor once and a while, by thinking it does something else but that usually come by the dicourse we're in the diaspora from. What did you come from, that made it so obvious to ignore the documentation?? how can I get just the tables ? I need just the tables You can get it by applescript BTW! --sd
genevieve charbon Posted July 28, 2006 Author Posted July 28, 2006 You can get it by applescript BTW! Did you try ? because all my rant is precisely targetted at the APPLESCRIPT table class. I don't talk about the design function, but the applescript class. Precisely I tried it with applescript and applescripts returns me the table occurence (instead of the tables that the wording "tables" of applescript implies), hence my (justified) rant. I'd be more than pleased to be proved wrong and have applescript returns the tables and not the table occurence.
genevieve charbon Posted July 28, 2006 Author Posted July 28, 2006 For the record here's applescript's diactionary entry about tthe class table table n : Every table It doesn't says "Every table occurence" but it indeed returns "Every table occurences. and Fenton kind of confirms it (other than the fact that it counts table occurrences not tables). http://fmforums.com/forum/showtopic.php?tid/128477/post/128492/hl/table+occurence+fenton/
Søren Dyhr Posted July 28, 2006 Posted July 28, 2006 That's correct it's the table occurence when you use to count your way thru ...probably the creation order. The way you can deal with it is to make a TOG entirely dedicated to Applescripts dealings and call them something distictive, and use the names in applescript. --sd
genevieve charbon Posted July 28, 2006 Author Posted July 28, 2006 I don't want to modify the files in any way, because what I'm doing is a developper database of my solution. Like the DDR database Filemaker 6 did (but easier to use). I want it to work on any solution, so I don't want to change the solution in any way. I know there's the xml and html ddr, but they require fmpa, and they're slow to generate (the html version), and not very easy to manipulate. What I want, is a database containing all my fields of my solution, all it's scripts etc. I'm forced to this because FMP is a nightmare to use. It takes me more time to find the sript I want to edit in the script editor than to code it !.
genevieve charbon Posted July 28, 2006 Author Posted July 28, 2006 (edited) To be clear my "developer database" is to be opened alongside all the files of the solution I want to scan. an applescript walk through every databases, and tables of the solution and put their fields/scripts/layouts in a "field" table, a "script" table, and a "layout" table of my "developper database". So the first step is to get all the databases names, and all their tables names to walk them through. It work nicely, except that, due to the fact that "tables" returns "tables occurence" instead of just tables, the script scans a lot more than it should and generates a lot of duplicates. To avoid that I need to just walk through the tables, not the table occurence. P.S Since my solution as 25 files with 3-4 tables each, reporting them by hand would be tedious, and won't allow my "developer database" to work on every solution Edited July 28, 2006 by Guest
Søren Dyhr Posted July 28, 2006 Posted July 28, 2006 I know there's the xml and html ddr, but they require fmpa, and they're slow to generate (the html version), and not very easy to manipulate. No make a new file, and use the SFI model to address your data: http://www.newcenturydata.com/downloads/separation_demo.zip --sd
Fenton Posted July 28, 2006 Posted July 28, 2006 How about a compromise. Use a naming convention so that you can recognize the "base tables". For example, a double underscore. Then you can skip the other ones. They would have to be on the Relationship Graph, but that would usually be true.
genevieve charbon Posted July 29, 2006 Author Posted July 29, 2006 Use a naming convention so that you can recognize the "base tables". Well, can I change the names of my base table in my current solution, without breaking anything . Value-lists, field calculations, scripts ?
Søren Dyhr Posted July 29, 2006 Posted July 29, 2006 What's a "SFI model" You didn't investigate the link I gave you apparently - or the idea didn't make it click?? I never though of this before, but it seems very very convenient to use the separation model for such a task. Make a new file and make file references to each of the old files and pull in one and just table occurence of each table the solution consists of, similar could all valuelist definitions be pulled in. There will no need for the new files intial table, so zap it of your RD eventhough it makes the file completely layout empty - and applescript is ready to rock. There seems no need to interconnect the TO's ushered in BTW. Here comes the great news you can then in the SFI rename the TO's to your hearts desire. The SFI file is the only file to open, and you can do stuff like this: tell application "FileMaker Pro Advanced" set aVar to record 1 of table 3 set item 3 of aVar to "Søren" copy aVar to record 1 of table 3 end tell ...since there in this new file only is one TO of each table is it as close to writing directly to a table!!! --sd
Fenton Posted July 29, 2006 Posted July 29, 2006 (edited) Well, can I change the names of my base table in my current solution, without breaking anything. Yes. But what really matters is the names on the Relationship Graph. If your naming convention is consistent, then it would not be difficult to do a little text parsing in AppleScript to remove the prefixes. Example: Inv__Invoices set theTO to "INV__Invoices" set pos to (offset of "__" in theTO) + 2 set tableName to text from pos to end of theTO [more] set theTables to {} set fm_file to choose file of type "FMP7" tell application "Finder" set db_name to name of fm_file end tell tell application "FileMaker Pro Advanced" set theTOs to name of tables of database db_name end tell repeat with i in theTOs if i contains "__" then set pos to (offset of "__" in i) + 2 set tableName to text from pos to end of i if theTables is {} then set theTables to tableName else set theTables to theTables & return & tableName end if end if end repeat I already use this naming convention for all my "anchor" table occurrences. It puts the name at the top of the table's TO's in a list. I don't always have one for every table however, not for join tables, etc.. So I'd have to do that. Søren has a good idea; simpler in many ways. It's too bad you can't copy/paste TO's from one file to another. Here's another method for it. Create another little file. Delete the default table. Since you have FileMaker 8 Advanced you could just copy/paste your real file's tables into a new file. They'll each get a TO on the Relationship Graph. That should do it. It depends on how many tables and fields you have, but I think it would be fairly quick. Then read those with AppleScript; or TableNames(Get(Filename)). Edited July 29, 2006 by Guest
Fenton Posted July 29, 2006 Posted July 29, 2006 About the DDR. I recently did a DDR from a huge solution: 3 files, almost a hundred tables, 500+ relationships. Using FileMaker 8.5 on my iMac Intel. I did it as XML (with NO open afterwards). It took 45 seconds!! I couldn't believe it was done. But it was. The xml files were over 100 MB, and that's a lot of text. I then imported the xml summary into a FileMaker solution, created by Jonathon Stark (of the Moyer Group). It's name is Process DDR, and it's available here (along with some other good stuff -): http://www.jonathanstark.com/downloads.php It uses xsl to bring in the basic FileMaker objects, into a simple FileMaker file. Fields, relationships, scripts and steps. It only takes a few minutes to bring this stuff in. In other words, it ain't no Analyzer or Inspector; it's only the basics, but it's faster, and it's free.
Recommended Posts
This topic is 6690 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