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. sql server 2000

sql server 2000

Scheduled Pinned Locked Moved Database
databasesql-serversysadmin
2 Posts 2 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.
  • K Offline
    K Offline
    kulandaivel_mca2007
    wrote on last edited by
    #1

    uid class section doj status 75 L.K.G A 2008-12-09 PRESENT 81 L.K.G A 2008-12-09 ABSENT 75 L.K.G A 2008-12-10 PRESENT 81 L.K.G A 2008-12-09 PRESENT 82 L.K.G A 2008-12-09 PRESENT 84 L.K.G A 2008-12-09 PRESENT 57 L.K.G A 2008-12-09 PRESENT 58 L.K.G A 2008-12-09 PRESENT 64 L.K.G A 2008-12-09 PRESENT 65 L.K.G A 2008-12-09 PRESENT 66 L.K.G A 2008-12-09 PRESENT 67 L.K.G A 2008-12-09 PRESENT 69 L.K.G A 2008-12-09 PRESENT 68 L.K.G A 2008-12-09 PRESENT 70 L.K.G A 2008-12-09 PRESENT 71 L.K.G A 2008-12-09 PRESENT 72 L.K.G A 2008-12-09 PRESENT 73 L.K.G A 2008-12-09 PRESENT 74 L.K.G A 2008-12-09 PRESENT 81 L.K.G A 2008-12-12 PRESENT 81 L.K.G A 2008-12-12 PRESENT 81 L.K.G A 2008-12-12 PRESENT 81 L.K.G A 2008-12-12 ABSENT select top 5 * from TBL_SATTENDANCE_lkg where uid not in (select top 7 uid from TBL_SATTENDANCE_lkg) 58 L.K.G A 2008-12-09 PRESENT 64 L.K.G A 2008-12-09 PRESENT 65 L.K.G A 2008-12-09 PRESENT 66 L.K.G A 2008-12-09 PRESENT 67 L.K.G A 2008-12-09 PRESENT ************************************************************* 75 L.K.G A 2008-12-09 PRESENT 81 L.K.G A 2008-12-09 ABSENT 75 L.K.G A 2008-12-10 PRESENT 81 L.K.G A 2008-12-09 PRESENT 82 L.K.G A 2008-12-09 PRESENT 84 L.K.G A 2008-12-09 PRESENT 57 L.K.G A 2008-12-09 PRESENT 58 L.K.G A 2008-12-09 PRESENT 64 L.K.G A 2008-12-09 PRESENT 65 L.K.G A 2008-12-09 PRESENT 66 L.K.G A 2008-12-09 PRESENT 67 L.K.G A 2008-12-09 PRESENT 69 L.K.G A 2008-12-09 PRESENT 68 L.K.G A 2008-12-09 PRESENT 70 L.K.G A 2008-12-09 PRESENT 71 L.K.G A 2008-12-09 PRESENT 72 L.K.G A 2008-12-09 PRESENT 73 L.K.G A 2008-12-09 PRESENT 74 L.K.G A 2008-12-09 PRESENT 81 L.K.G A 2008-12-12 PRESENT 81 L.K.G A 2008-12-12 PRESENT 81 L.K.G A 2008-12-12 PRESENT 81 L.K.G A 2008-12-12 ABSENT select top 5 * from TBL_SATTENDANCE_lkg where uid not in (select top 2 uid from TBL_SATTENDANCE_lkg where uid = 81) 75 L.K.G A 2008-12-09 PRESENT 75 L.K.G A 2008-12-10 PRESENT 82 L.K.G A 2008-12-09 PRESENT 84 L.K.G A 2008-12-09 PRESENT 57 L.K.G A 2008-12-09 PRESENT *********************************************** I NEED THIS RESULT(i.e) i want result except top 3 record with uid 81 (other records with uid 81) 81 L.K.G A 2008-12-12 PRESENT 81 L.K.G A 2008-12-12 PRESENT 81 L.K.G A 2008-12-12 ABSENT ***************************************************** select top 3 * from TBL_SATTENDANCE_lkg where uid=81 not in (select top 3 uid from TBL_SATTENDANCE_lkg where uid = 81) i try this but it won,t work...

    B 1 Reply Last reply
    0
    • K kulandaivel_mca2007

      uid class section doj status 75 L.K.G A 2008-12-09 PRESENT 81 L.K.G A 2008-12-09 ABSENT 75 L.K.G A 2008-12-10 PRESENT 81 L.K.G A 2008-12-09 PRESENT 82 L.K.G A 2008-12-09 PRESENT 84 L.K.G A 2008-12-09 PRESENT 57 L.K.G A 2008-12-09 PRESENT 58 L.K.G A 2008-12-09 PRESENT 64 L.K.G A 2008-12-09 PRESENT 65 L.K.G A 2008-12-09 PRESENT 66 L.K.G A 2008-12-09 PRESENT 67 L.K.G A 2008-12-09 PRESENT 69 L.K.G A 2008-12-09 PRESENT 68 L.K.G A 2008-12-09 PRESENT 70 L.K.G A 2008-12-09 PRESENT 71 L.K.G A 2008-12-09 PRESENT 72 L.K.G A 2008-12-09 PRESENT 73 L.K.G A 2008-12-09 PRESENT 74 L.K.G A 2008-12-09 PRESENT 81 L.K.G A 2008-12-12 PRESENT 81 L.K.G A 2008-12-12 PRESENT 81 L.K.G A 2008-12-12 PRESENT 81 L.K.G A 2008-12-12 ABSENT select top 5 * from TBL_SATTENDANCE_lkg where uid not in (select top 7 uid from TBL_SATTENDANCE_lkg) 58 L.K.G A 2008-12-09 PRESENT 64 L.K.G A 2008-12-09 PRESENT 65 L.K.G A 2008-12-09 PRESENT 66 L.K.G A 2008-12-09 PRESENT 67 L.K.G A 2008-12-09 PRESENT ************************************************************* 75 L.K.G A 2008-12-09 PRESENT 81 L.K.G A 2008-12-09 ABSENT 75 L.K.G A 2008-12-10 PRESENT 81 L.K.G A 2008-12-09 PRESENT 82 L.K.G A 2008-12-09 PRESENT 84 L.K.G A 2008-12-09 PRESENT 57 L.K.G A 2008-12-09 PRESENT 58 L.K.G A 2008-12-09 PRESENT 64 L.K.G A 2008-12-09 PRESENT 65 L.K.G A 2008-12-09 PRESENT 66 L.K.G A 2008-12-09 PRESENT 67 L.K.G A 2008-12-09 PRESENT 69 L.K.G A 2008-12-09 PRESENT 68 L.K.G A 2008-12-09 PRESENT 70 L.K.G A 2008-12-09 PRESENT 71 L.K.G A 2008-12-09 PRESENT 72 L.K.G A 2008-12-09 PRESENT 73 L.K.G A 2008-12-09 PRESENT 74 L.K.G A 2008-12-09 PRESENT 81 L.K.G A 2008-12-12 PRESENT 81 L.K.G A 2008-12-12 PRESENT 81 L.K.G A 2008-12-12 PRESENT 81 L.K.G A 2008-12-12 ABSENT select top 5 * from TBL_SATTENDANCE_lkg where uid not in (select top 2 uid from TBL_SATTENDANCE_lkg where uid = 81) 75 L.K.G A 2008-12-09 PRESENT 75 L.K.G A 2008-12-10 PRESENT 82 L.K.G A 2008-12-09 PRESENT 84 L.K.G A 2008-12-09 PRESENT 57 L.K.G A 2008-12-09 PRESENT *********************************************** I NEED THIS RESULT(i.e) i want result except top 3 record with uid 81 (other records with uid 81) 81 L.K.G A 2008-12-12 PRESENT 81 L.K.G A 2008-12-12 PRESENT 81 L.K.G A 2008-12-12 ABSENT ***************************************************** select top 3 * from TBL_SATTENDANCE_lkg where uid=81 not in (select top 3 uid from TBL_SATTENDANCE_lkg where uid = 81) i try this but it won,t work...

      B Offline
      B Offline
      Blue_Boy
      wrote on last edited by
      #2

      You was near to result wich you want to get. I have modify your query and it shows right result. select top 3 * from TBL_SATTENDANCE_lkg where uid=81 or uid not in (select top 3 uid from TBL_SATTENDANCE_lkg where uid = 81) Hope it will helps you...


      I Love T-SQL "Don't torture yourself,let the life to do it for you." If my post helps you kindly save my time by voting my post.

      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