Translating with DrWatson… this can take a few seconds the first time.
This is a genuine, complex translation. DrWatson protects commands, error codes, and log output while naturally translating the surrounding text. It’s translated once and saved.
In article <62980009@col.hp.com> judym@col.hp.com (Judy Miller) writes:
>Problem: I have a list of keys to 4000 records which I need to delete from
> a table of 12000.
>
>I'm trying to avoid writing a program for this common function.
>(I do not have 4GL on this machine, but I do have ESQL/C.)
Try this one:
1. load the key list into a (temporary) table
(create table, load from .. etc.)
2. Then delete records by executing:
delete from orig_table
where key_field in (
select * from temp_table
)
3. Then drop key list, if not created by create temp table ..
-svb.
--
Sebastian v. Bomhard <svb@guug.de> Mathematiker und EDV-Journalist
St.-Anna-Str. 13, D-W-8000 Muenchen 22 (Lehel), +49-89-298934
We use strictly necessary cookies to make this site work. With your
consent we’d also use optional cookies for analytics and marketing. You can accept all,
reject all, or choose. Read our Cookie Policy.