March 30, 201312 yr I am using FM 12 advanced  I have an import script that first deletes all tables and then imports tables from a previous, specified version.  Recently FM has decided that it will not remember the Source table for my Global table import.   I turn 'perform without dialog' OFF, change the Source table and everything works great. Then I turn 'perform without dialog' ON and it goes back to it's old way of not remembering the Source table.  What's the 'magic' trick here?  Thanks  ron
March 30, 201312 yr No trick, it should just work once you set it in your script. You are not really deleting tables are you? I'm assuming you meant records...
March 30, 201312 yr Author Thanks for the reply. To elaborate a bit, the source Global table has, over several versions, developed over 10,000 records. I only need 1. So, I can import the source 10,000 records and then delete them in the target. That seems to work. But, a better solution would be to delete all the records in the Source Global table BEFORE I import. I have collected the user selected Source file path and filename in a variable called $$path. Since the import module is run from the Target and I don't know what the Source might be I am looking for a 'trick' to avoid the apparent process: open the source, goto the Global layout, delete all records, close the Source, continue the Target import script... Is there an easier way to do this?
March 31, 201312 yr Another solution is to check there is only one record, then import with the option to update existing records.
March 31, 201312 yr Author Another solution is to check there is only one record, then import with the option to update existing records. I had no idea my previous import script was accumulating thousands of duplicate records. So, now the situation is I need to import a source with 10,000 duplicate global records. Once they are imported, I can easily delete all but 1 record. The question is "How do I delete 9,999 source records BEFORE I import them? (Given that I do not know the import file name; only the global variable , $$path, that hold the Source path and filename.fmpr) Thank you for the input Ron
March 31, 201312 yr hi, Ron G: Why not check out the "Updating Local Files" technique from Matt Petrowsky - it has some ideas you could use to make this work. Matt does point out that at least one record is required for the solution to work, so it includes "Show All", followed by "Omit Record", then "Show Omitted". He lso sets up "External Data Sources" to include the "temp" file. - - Scott
October 25, 201312 yr No trick, it should just work once you set it in your script. You are not really deleting tables are you? I'm assuming you meant records... Sorry to open it again. I have this expirience. When I set-up all the mappings it works well until I'll close database. After reopening all mappings gets lost and I have to setup again. I've tried to "save it" in local file as well as on the remote file with same results. What I'm doing wrong? Thank you
Create an account or sign in to comment