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. Index seek and Index scan

Index seek and Index scan

Scheduled Pinned Locked Moved Database
databasetutorial
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.
  • D Offline
    D Offline
    dayakar_dn
    wrote on last edited by
    #1

    Hi, If i am writing simple select query like Declare @parentInventoryId int SELECT InventoryID FROM Inventory_Profile WHERE ParentInventoryID=@parentInventoryId In query execution plan i am getting index scan, but i need index seek can anybody tell how to change the query to get index seek in my query execution plan

    W 1 Reply Last reply
    0
    • D dayakar_dn

      Hi, If i am writing simple select query like Declare @parentInventoryId int SELECT InventoryID FROM Inventory_Profile WHERE ParentInventoryID=@parentInventoryId In query execution plan i am getting index scan, but i need index seek can anybody tell how to change the query to get index seek in my query execution plan

      W Offline
      W Offline
      woudwijk
      wrote on last edited by
      #2

      On what column do you get an indexscan ? did you make indexes ? on what columns ? did you make a covering index ? by adding the requested data and the filtering data in one index, sql does not have to go to the table itself, just the index is enough how many rows of data are there in this table ? SQL server ignores indexes when there are few rows of data My second computer is your linux box.

      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