home *** CD-ROM | disk | FTP | other *** search
- Path: sparky!uunet!spool.mu.edu!sdd.hp.com!zaphod.mps.ohio-state.edu!swrinde!emory!emory!not-for-mail
- From: unifi!goofy.unifi.com!bharat@uunet.UU.NET (Bharat Shah)
- Newsgroups: comp.databases.informix
- Subject: Re: UPDATE problem on UNIQUEly INDEXed table on DOS
- Date: 6 Jan 1993 18:23:06 -0500
- Organization: Mailing List Gateway
- Lines: 23
- Sender: walt@mathcs.emory.edu
- Distribution: world
- Message-ID: <1ifpkqINNlc9@emory.mathcs.emory.edu>
- Reply-To: unifi!goofy.unifi.com!bharat@uunet.UU.NET (Bharat Shah)
- NNTP-Posting-Host: emory.mathcs.emory.edu
- X-Informix-List-ID: <list.1753>
-
- Use the following:
-
- begin work
-
- update fartigos /* Shift things beyond N */
- set c_int_art = c_int_art + N + 1
- where c_int_g = ....
- .. and c_int_art >= K
-
- insert into fartigos values (....., K) /* Place your stuff */
-
- update fartigos /* Bring back records into domain */
- set c_int_art = c_int_art - N
- where c_int_g = ...
- and c_int_art >= K+N
-
- commit work
-
- ========================================================================
- Bharat Shah Voice: (508)-663-7570
- Unifi Communications Corp. Fax: (508)-663-7543
- 4 Federal St, Billerica, Mass 01821, USA uunet!bharat@unifi.com
- ========================================================================
-