February 6, 2013 at 5:15 am
Hi All,
I have a question because i confused........
>> What is Index Key Value ?
Can any one explain with proper example.
Regards,
Sachin.
February 6, 2013 at 6:50 am
Indexing:
http://www.sqlservercentral.com/articles/Indexing/68439/
http://www.sqlservercentral.com/articles/Indexing/68563/
http://www.sqlservercentral.com/articles/Indexing/68636/
When you create an index, the column or set of columns that the index is created on is the key columns.
Gail Shaw
Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability
February 7, 2013 at 3:02 am
Hi Mr. Gail Shaw,
Don't mind but i am not getting below sentence.
The key columns (also referred to as the index key) can be likened to the terms listed in a book index. They are the values that the index will be used to search for. As with the index found at the back of a text book (see figure 1), the index is sorted by the key columns.
Regards,
Sachin.
February 7, 2013 at 3:14 am
dsachu (2/7/2013)
Hi Mr. Gail Shaw,Don't mind but i am not getting below sentence.
The key columns (also referred to as the index key) can be likened to the terms listed in a book index. They are the values that the index will be used to search for. As with the index found at the back of a text book (see figure 1), the index is sorted by the key columns.
Regards,
Sachin.
1st Gail is a lady, so Mr. isn't the correct title to address her by.
2nd. I am sure you have read a book at some point (non-novel), at the back of the book there is an index, with a list of major topics, sorted in order from A - Z. That is the same methodology that a SQL index takes, it is a way to search quickly for what you want to find. Eg. I want information on Blocking, look in the index, find the page numbers which blocking is refered to, then you know where to look for the information. Same in SQL, I want to look for all people who have a first name 'Anthony', SQL looks in the index, finds the right page numbers where the name 'Anthony' appears and you get the information you need.
February 7, 2013 at 3:40 am
Hi,
Sorry.....actual on the basis of Gail Photo, I assume he is Mr.
----------
I have Table ABC. Where I have one Column Country id on which I have implemented primary key .
What will be Index key value in below given table.
As per my understanding 1,2,3,4,5 will be the index key value......is am right ?
Country ID (PK)Country Name
--------------- --------------
1 UK
2 US
3 Japan
4 India
5 China
Regards,
Sachin.
February 7, 2013 at 3:44 am
dsachu (2/7/2013)
Hi,Sorry.....actual on the basis of Gail Photo, I assume he is Mr.
----------
I have Table ABC. Where I have one Column Country id on which I have implemented primary key .
What will be Index key value in below given table.
As per my understanding 1,2,3,4,5 will be the index key value......is am right ?
Country ID (PK)Country Name
--------------- --------------
1 UK
2 US
3 Japan
4 India
5 China
Regards,
Sachin.
Correct, that ever is in the create index statement (exlcuding included columns) is the index key value
EG.
CREATE INDEX IDX_Name ON Ant (Name) - Index Key value is Name
CREATE INDEX IDX_Name_DOB ON Ant (Name,DOB) - Index Key value is Name & DOB
CREATE INDEX ISX_Name_DOB ON Ant (Name,DOB) INCLUDE (Salary) - Index Key value is Name & DOB
February 7, 2013 at 3:59 am
Hi
Again some confusion.
-------------------------
>> CREATE INDEX IDX_Name ON Ant (Name) - Index Key value is Name
Ant is your column right ? and Name is one record in this column
>> CREATE INDEX IDX_Name_DOB ON Ant (Name,DOB) - Index Key value is Name & DOB
Ant is your column right ? and Name and DOB is two different record in this column
Please clarify.
Regards,
Sachin.
February 7, 2013 at 4:01 am
No, Ant is the table, the columns are Name, DOB, Salary.
Take a look at the CREATE INDEX syntax.
Indexes are not defined on row, they are defined on columns.
February 7, 2013 at 4:04 am
Then what will be Index Key in your example.
February 7, 2013 at 4:06 am
The data inside columns inside the brackets.
The Index Key is the columns, the value is the data inside the columns
February 7, 2013 at 4:17 am
anthony.green (2/7/2013)
The data inside columns inside the brackets.The Index Key is the columns, the value is the data inside the columns
It means in your Example :
Table : Ant
Column :
Name ( Index Key )
-----------------------------
Sachin ( Index Key Value )
Gail ( Index Key Value )
Rakesh ( Index Key Value )
Antony ( Index Key Value )
I think now I am absolutely right....if you will confirm that i am right then my confusion will be end.
Regards,
February 7, 2013 at 4:18 am
dsachu (2/7/2013)
anthony.green (2/7/2013)
The data inside columns inside the brackets.The Index Key is the columns, the value is the data inside the columns
It means in your Example :
Table : Ant
Column :
Name ( Index Key )
-----------------------------
Sachin ( Index Key Value )
Gail ( Index Key Value )
Rakesh ( Index Key Value )
Antony ( Index Key Value )
I think now I am absolutely right....if you will confirm that i am right then my confusion will be end.
Regards,
correct
February 7, 2013 at 4:44 am
anthony.green (2/7/2013)
dsachu (2/7/2013)
anthony.green (2/7/2013)
The data inside columns inside the brackets.The Index Key is the columns, the value is the data inside the columns
It means in your Example :
Table : Ant
Column :
Name ( Index Key )
-----------------------------
Sachin ( Index Key Value )
Gail ( Index Key Value )
Rakesh ( Index Key Value )
Antony ( Index Key Value )
I think now I am absolutely right....if you will confirm that i am right then my confusion will be end.
Regards,
correct
last one more thing on the basis of book index......
suppose i have content where i would like to know from your side what will be Index Key & Index key value in below given scenario..
abstraction, services795
access control list732
accessing hardware counter573
this is last scenario please...
February 7, 2013 at 5:02 am
Depends on the table definition and the columns
Index Key is the column
Index Key value, is the data in the column
February 7, 2013 at 5:37 am
anthony.green (2/7/2013)
Depends on the table definition and the columnsIndex Key is the column
Index Key value, is the data in the column
Hi,
Please clarify below statement.
>>In the leaf level, there’s one entry for each row in the index. The entries in the index are ordered logically in the order of the index key.
I am not getting [b]there’s one entry for each row in the index[/b]
Regards,
Sachin.
Viewing 15 posts - 1 through 15 (of 15 total)
You must be logged in to reply to this topic. Login to reply