﻿<?xml version='1.0' encoding='UTF-8'?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/"><channel><title>SQLServerCentral / Article Discussions / Article Discussions by Author / Discuss content posted by tklimczak  / Generate index on foreign key columns / Latest Posts</title><generator>InstantForum.NET v2.9.0</generator><description>SQLServerCentral</description><link>http://www.sqlservercentral.com/Forums/</link><webMaster>notifications@sqlservercentral.com</webMaster><lastBuildDate>Tue, 21 May 2013 20:57:05 GMT</lastBuildDate><ttl>20</ttl><item><title>RE: Generate index on foreign key columns</title><link>http://www.sqlservercentral.com/Forums/Topic449223-1189-1.aspx</link><description>How can we modify this script to :- Rename [u]all[/u] PK indexes to "IX_[TableName];- Rename [u]all[/u] FK indexes to "IX_[TableName]_[ColumnName]";Thanks</description><pubDate>Thu, 05 Feb 2009 02:01:31 GMT</pubDate><dc:creator>mickael.mottet</dc:creator></item><item><title>RE: Generate index on foreign key columns</title><link>http://www.sqlservercentral.com/Forums/Topic449223-1189-1.aspx</link><description>[quote][b]Mike Byrd (3/4/2008)[/b][hr]There are times when an index is not needed for a foreign key.  If the table is small (low number of rows) or the index column has little selectivity, then why add the overhead of an index?  I wrote a similar script about a month ago, but found that the were many times the index just wasn't needed.[/quote]It can be run as just a select first to pull up a list for evaluation.  A starting point like that can be useful when you're trying to tune an inherited database.</description><pubDate>Tue, 04 Mar 2008 12:48:38 GMT</pubDate><dc:creator>srienstr</dc:creator></item><item><title>RE: Generate index on foreign key columns</title><link>http://www.sqlservercentral.com/Forums/Topic449223-1189-1.aspx</link><description>There are times when an index is not needed for a foreign key.  If the table is small (low number of rows) or the index column has little selectivity, then why add the overhead of an index?  I wrote a similar script about a month ago, but found that the were many times the index just wasn't needed.</description><pubDate>Tue, 04 Mar 2008 12:32:41 GMT</pubDate><dc:creator>Mike Byrd</dc:creator></item><item><title>RE: Generate index on foreign key columns</title><link>http://www.sqlservercentral.com/Forums/Topic449223-1189-1.aspx</link><description>Which version of SQL Server is this written for?  I've got 2000, and neither the table names nor column names match the system tables.</description><pubDate>Tue, 04 Mar 2008 09:09:24 GMT</pubDate><dc:creator>srienstr</dc:creator></item><item><title>RE: Generate index on foreign key columns</title><link>http://www.sqlservercentral.com/Forums/Topic449223-1189-1.aspx</link><description>Does this work where the foreign key constraint consists of more than one column?John</description><pubDate>Tue, 04 Mar 2008 02:09:00 GMT</pubDate><dc:creator>John Mitchell-245523</dc:creator></item><item><title>Generate index on foreign key columns</title><link>http://www.sqlservercentral.com/Forums/Topic449223-1189-1.aspx</link><description>Comments posted to this topic are about the item [B]&lt;A HREF="/scripts/Index+Management/62069/"&gt;Generate index on foreign key columns&lt;/A&gt;[/B]</description><pubDate>Wed, 30 Jan 2008 02:16:48 GMT</pubDate><dc:creator>tklimczak</dc:creator></item></channel></rss>