home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #20 / NN_1992_20.iso / spool / comp / database / sybase / 8 < prev    next >
Encoding:
Text File  |  1992-09-14  |  980 b   |  26 lines

  1. Newsgroups: comp.databases.sybase
  2. Path: sparky!uunet!cs.utexas.edu!torn!cunews!nrcnet0!netfs!manitou.cse.dnd.ca!pburry
  3. From: pburry@manitou.cse.dnd.ca (Paul Burry)
  4. Subject: Re: Sequencer or Serial
  5. Message-ID: <1992Sep15.025550.27360@manitou.cse.dnd.ca>
  6. Organization: Canadian System Security Centre
  7. References: <14821@gazette.bcm.tmc.edu> <howard.716504676@judy.cs.iastate.edu> <06ynl+l.mcentral@netcom.com>
  8. Date: Tue, 15 Sep 92 02:55:50 GMT
  9. Lines: 15
  10.  
  11. In article <06ynl+l.mcentral@netcom.com> mcentral@netcom.com (Media Central) writes:
  12. . . .
  13. |begin tran
  14. |   update sequenc set col = col + 1        /* update first and then read */
  15. |   select @latest = col from sequenc where 1 = 1
  16. |end tran
  17. . . .
  18.  
  19. Why the 'where 1 = 1' ?  Is this some obscure optimizer work-around?
  20.  
  21. -- 
  22. =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
  23. Paul Burry            
  24. Voice: (613)-991-7325        Internet: pburry@cse.dnd.ca
  25. Fax:   (613)-991-7323        UUCP:      ..!{uunet,cunews}!cse.dnd.ca!pburry
  26.