Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. Database & SysAdmin
  3. Database
  4. NEXT AND PREVIOUS RECORDS

NEXT AND PREVIOUS RECORDS

Scheduled Pinned Locked Moved Database
databasesql-serversysadminquestion
5 Posts 4 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • S Offline
    S Offline
    Sonia Gupta
    wrote on last edited by
    #1

    IS THERE ANY PROVISION TO ASCERTAIN NEXT AND PREVIOUS RECORD IN SQL SERVER 2000 ?

    Yesterday is a canceled check. Tomorrow is a promissory note. Today is the ready cash. USE IT.

    C P 2 Replies Last reply
    0
    • S Sonia Gupta

      IS THERE ANY PROVISION TO ASCERTAIN NEXT AND PREVIOUS RECORD IN SQL SERVER 2000 ?

      Yesterday is a canceled check. Tomorrow is a promissory note. Today is the ready cash. USE IT.

      C Offline
      C Offline
      Colin Angus Mackay
      wrote on last edited by
      #2

      Sonia Gupta wrote:

      IS THERE ANY PROVISION TO ASCERTAIN NEXT AND PREVIOUS RECORD IN SQL SERVER 2000 ?

      Databases are set based. There is no concept of next and previous row. Any database that does this is working on a fiction. ORDER BY can be used to impose an order on the result set, but again this is a fiction to make things easier for the calling application. It may appear that a database is returning data in a specific order all the time, but this is merely a side-effect of the physical implementation and not something you can rely on.

      Upcoming FREE developer events: * Developer Day Scotland Recent blog posts: * Mixins in C#3.0 My website | Blog

      1 Reply Last reply
      0
      • S Sonia Gupta

        IS THERE ANY PROVISION TO ASCERTAIN NEXT AND PREVIOUS RECORD IN SQL SERVER 2000 ?

        Yesterday is a canceled check. Tomorrow is a promissory note. Today is the ready cash. USE IT.

        P Offline
        P Offline
        Pete OHanlon
        wrote on last edited by
        #3

        Don't shout. Please use mixed case. You can find next and previous records, but the queries are likely to be fairly "hairy". As Colin states, SQL is set based so you have to figure out how to work on the set.

        Deja View - the feeling that you've seen this post before.

        My blog | My articles

        M 1 Reply Last reply
        0
        • P Pete OHanlon

          Don't shout. Please use mixed case. You can find next and previous records, but the queries are likely to be fairly "hairy". As Colin states, SQL is set based so you have to figure out how to work on the set.

          Deja View - the feeling that you've seen this post before.

          My blog | My articles

          M Offline
          M Offline
          martin_hughes
          wrote on last edited by
          #4

          oK PeTE, iT's miXeD CAsE fRoM heRE oN In. :)

          P 1 Reply Last reply
          0
          • M martin_hughes

            oK PeTE, iT's miXeD CAsE fRoM heRE oN In. :)

            P Offline
            P Offline
            Pete OHanlon
            wrote on last edited by
            #5

            That's much better.

            Deja View - the feeling that you've seen this post before.

            My blog | My articles

            1 Reply Last reply
            0
            Reply
            • Reply as topic
            Log in to reply
            • Oldest to Newest
            • Newest to Oldest
            • Most Votes


            • Login

            • Don't have an account? Register

            • Login or register to search.
            • First post
              Last post
            0
            • Categories
            • Recent
            • Tags
            • Popular
            • World
            • Users
            • Groups