| Expression to Insert Value from Destination Table | |
Posted: Tue Feb 01, 2011 1:40 pm |
Points: 0 |
|
davidshq |
GoldMine Journeyman |
|
|
Joined: 15 Jun 2010 |
Posts: 38 |
|
|
|
|
|
|
|
|
Okay, so I didn't understand that GXI was just a table that contained the info. from my source database, and not also the info. from the destination database. I'm trying to update a field, conditionally, with a value but if it doesn't have that value I want to keep the orginal destination database value...how can I do that?
e.g.
If Tx->Phone1 is Empty Get DestinationDb->Phone1.
Dave. |
|
|
|
|
| | |
Posted: Tue Feb 01, 2011 6:45 pm |
Points: 1 |
|
Paul Laufer |
GoldBox Guru |
|
|
Joined: 27 Oct 2008 |
Posts: 125 |
|
|
|
|
|
|
|
|
During an import, there's TWO temporary DBF files. GXI and TGT. GXI acts as the incoming file and TGT acts as the target database.
GoldBox imports into GXI first, and then updates into TGT after. Those are called the import phase and the update phase. Once TGT is updated, the values are moved up to SQL.
So at the import phase your expressions have access to the source file and the GXI file. At the update phase you have access to the GXI file and the TGT file.
At the top of the map fields screen is a button called "GXI Field Filled" which is probably what you want. It will create an "update expression" that looks something like the following...
IIF(Empty(GXI->Phone1), Tgt->Phone1, GXI->Phone1)
That says in English... if the incoming phone is empty, use the existing phone, else use the incoming phone. |
|
|
|
|
| | |
Posted: Sat Mar 26, 2011 5:33 am |
Points: 0 |
|
davidshq |
GoldMine Journeyman |
|
|
Joined: 15 Jun 2010 |
Posts: 38 |
|
|
|
|
|
|
|
|
Thanks Paul. That was very helpful.
Dave. |
|
|
|
|
ContactReview Forum Index » GoldBox
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
All times are GMT - 7 Hours
Page 1 of 1
|
|
|
Brought to you by Castell Computers, Doug Castell, Admin
Powered by phpBB © 2001-2004 phpBB Group Theme created by Vjacheslav Trushkin
|