Vjeran Posted May 13, 2006 Posted May 13, 2006 Hi, How to make FM script to import data from two files (.tab)in FMP in same record in two fields? Thx VJ
LaRetta Posted May 13, 2006 Posted May 13, 2006 (edited) Hi VJ, You import each file separately. A few questions: 1) Are the 'receiving' TARGET records already in your file or would the first import create them? 2) Do records in either of these two SOURCE imports contain the same information? 3) What designates which field-value should go in which field in which record in your solution? In simpler terms ... what would be the match field which determines your import map? added ---> what one single bit of information do these two source imports have in common xor what do these files have in common with your target (existing) records (if any). 4) Which file should be imported first (if there is a possibility of duplication)? This will take some planning to handle properly and it would determine whether records missing from one (of either of the files) will get added as new records. 5) Is this a one-time thing or an on-going need? We need to know more about a) your existing table which will hold the data and the fields/records coming in... In other words, each import (especially if matching & update existing is involved) needs to be home-spun on the spot after proper mapping. So, what's your data? And where do you want us to tell you to stick it? LaRetta Edited May 13, 2006 by Guest
Vjeran Posted May 13, 2006 Author Posted May 13, 2006 Hi LaRetta, 1) I can put Import to open new record, or I can put New record in FM script, both is fine with me (my file). 2) I have two external Tab files. One with Name and other with number (2 files with one record each). Record from file Name goes to field Name (text) and record from file Num goes to field Num. 3) The thing is that I need this Name and Num in same record where I have IDNum, and If Num=ID Num then FM script will export Name in VB Script etc. Num value is unpredictable. 4) This is on-going thing ... but unpredictable by time. All other data in the record are coming automaticly from VBS and actually there is no link with those which I need to import. ... back to LaRetta :smile2:
Vjeran Posted May 13, 2006 Author Posted May 13, 2006 ...breaking news .... I made it! I did`t use Export, I used Save As Excel, so I get two fields in one file which FM can Import in one record :yay:
Wim Decorte Posted May 14, 2006 Posted May 14, 2006 Since you're already using VBscript check out the VBscript plugin at www.grokittools.com. The neat thing with it is that it can return a result directly into FM. So you could write a VBscript to read and return the values without having to go through the import engine.
Vjeran Posted May 14, 2006 Author Posted May 14, 2006 WIM RULEZ! VBscript plugin is great solution, anyhow I will buy it. But for this project (for end user) I have limited budget. Thank you Wim VJ
Recommended Posts
This topic is 6768 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