On 13-2-2015 14:55, Kjell Rilbe kjell.ri...@datadia.se 
[firebird-support] wrote:
> I'm writing a utility that will need to do two things for each record in
> an external table and for this purpose I use a for select ... do
> construct in an execute block. I do it this way because external tables
> can't be indexed and I will scan the entire external table anyway.
>
> The two operations are:
> 1. Update one existing record in the target table.
> 2. Insert new record in the same target table.

Maybe you can use MERGE, it uses a source, a target and can 
conditionally insert, update (and delete) record? I assume your target 
table isn't external and is indexed.

Mark

-- 
Mark Rotteveel
  • [firebird-support] ... Kjell Rilbe kjell.ri...@datadia.se [firebird-support]
    • Re: [firebird-... Mark Rotteveel m...@lawinegevaar.nl [firebird-support]
      • Re: [fireb... Kjell Rilbe kjell.ri...@datadia.se [firebird-support]
    • Re: [firebird-... Kjell Rilbe kjell.ri...@datadia.se [firebird-support]

Reply via email to