Subject | Re: [IBO] TIB_Import |
---|---|
Author | Paul Vinkenoog |
Post date | 2003-11-14T23:00:24Z |
Hi Peter,
the time: I check the unique fields of the record to be inserted;
if they don't exist yet, I leave OKToPost true. If they exist
already, I set OKToPost false and - depending on the situation
and sometimes on user-provided parameters - either do nothing
(so the record is skipped) or I update the existing record using
a parameterized TIB_DSQL.
Your idea of using an SP might be quicker though! It may seem silly
to use a TIB_Import only to refuse every single record it wants to
insert but hey, if it works... why not?
Greetings,
Paul Vinkenoog
> I am using a TIB_Import successfully , however I need to do anI suppose you mean the TIB_Import.OnPrePost event? I use that all
> edit on a field if the key exists rather than an Insert.
> Is this possible using the before post or similar ?
>
> One way I thought of was to pick up on the before post event,
> pass the data to a stored procedure that does a edit / insert
> then skip the post in the TIB_Import.
the time: I check the unique fields of the record to be inserted;
if they don't exist yet, I leave OKToPost true. If they exist
already, I set OKToPost false and - depending on the situation
and sometimes on user-provided parameters - either do nothing
(so the record is skipped) or I update the existing record using
a parameterized TIB_DSQL.
Your idea of using an SP might be quicker though! It may seem silly
to use a TIB_Import only to refuse every single record it wants to
insert but hey, if it works... why not?
Greetings,
Paul Vinkenoog