Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
How to pull out the PK field for the table
Message
De
12/09/2008 12:23:09
 
 
Information générale
Forum:
Microsoft SQL Server
Catégorie:
Autre
Versions des environnements
SQL Server:
SQL Server 2005
Divers
Thread ID:
01347071
Message ID:
01347105
Vues:
17
This message has been marked as a message which has helped to the initial question of the thread.
Hi

EXEC sp_pkeys @table_name = tableName



>Hi everybody,
>
>I want to create a script that would check all my tables with character long (>100 char) fields for a certain word in them. If this word is found then I want to update this table based on its primary key from another "clean" table.
>
>My current problem is to get PK field for each table I identified in my query. I looked into sys.indexes, but It doesn't return the actual field name.
>
>Any ideas how can I get the information?
>
>Thanks a lot in advance.
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform