import question
Richard Kreiss
rkreiss at gccconsulting.net
Fri Nov 1 14:57:48 PDT 2019
You might consider chaining out to a separate import processing table based on what the value is in that first field.
I am not quite sure how to pass the the handle to the chained processing table or if you will need to close the fie and execute the import based on the processing table chained to. Keep in mind that depending on what you need to do after the chain, you wil either chain back to the original processing table to exit once the import is complete.
Keeping the processing tables separate an make it simpler to debug the import routines.
Once everything is working, you could combine the chain tables into on larger processing table using goto's or gosub's.
I still like the chain option as if there is an issue with one type of import you are only looking at as specific processing table and it will a debug will be easier. I have added a line to a number of processing table that only turn on the debugger if it is me running the processing. I sometimes forget to remove a debug on command and a client will call about the program not working. I also have a global flag that only executed the debug on once, so that when the debugger is given the quite or end command it doesn't not run on the next record.
Richard Kreiss
GCC Consulting
> -----Original Message-----
> From: Filepro-list <filepro-list-bounces+rkreiss=verizon.net at lists.celestial.com>
> On Behalf Of scooter6--- via Filepro-list
> Sent: Thursday, October 31, 2019 4:36 PM
> To: filePro Mailing List <filepro-list at lists.celestial.com>
> Subject: import question
>
> I will have ongoing csv files that I need to import into a filePro database
>
> The beginning of each line is static, in that it will say one of 4-5 things
> - based on field 1, it goes to a different part of the import
> There is one that will start with 'Charges|' (it's a pipe delimited
> file)
> The 2nd field is used to look up the record
>
> Each record in filePro can have up to 40 charges in it
>
> Since the inbound csv file won't necessarily be sorted in order of field 2 (the key
> to lookup the record) - is there a simpler way to know which field to put the new
> charge in vs having to say
>
> if charge field 1 is not "" but charge field 2 is blank, then put this charge in field 2
> and so on?
> The bottom line will be if all 40 charge fields are not empty, it will skip the record
> (which I have that part - ) just wondering if there's an easier way I'm not thinking
> of than to 'step' through each charge field until I find the first empty one....
>
> thanks
> Scott
> -------------- next part --------------
> An HTML attachment was scrubbed...
> URL: <http://mailman.celestial.com/pipermail/filepro-
> list/attachments/20191031/b137ff56/attachment.html>
> _______________________________________________
> Filepro-list mailing list
> Filepro-list at lists.celestial.com
> Subscribe/Unsubscribe/Subscription Changes
> http://mailman.celestial.com/mailman/listinfo/filepro-list
-------------- next part --------------
A non-text attachment was scrubbed...
Name: winmail.dat
Type: application/ms-tnef
Size: 11992 bytes
Desc: not available
URL: <http://mailman.celestial.com/pipermail/filepro-list/attachments/20191101/772f1981/attachment.bin>
More information about the Filepro-list
mailing list