Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
How to do Seek in SQL query?
Message
 
 
À
Tous
Information générale
Forum:
Microsoft SQL Server
Catégorie:
Autre
Titre:
How to do Seek in SQL query?
Versions des environnements
SQL Server:
SQL Server 2005
Divers
Thread ID:
01447540
Message ID:
01447540
Vues:
120
Hi,

I am trying to update a column of one table based on the value in another table. I could write a little VFP program to do it but I want to learn to do it in T-SQL. Here is what I want to do:

Table1 has column UserID nchar(8) and UserPk int.
Table2 has column UserID nchar(8) and UserPk int. The column UserPk has only 0 (zero). I want to update the entry in column UserPk of Table2 based on matching row (by UserID) in Table1.

How do you do it in T-SQL?
"The creative process is nothing but a series of crises." Isaac Bashevis Singer
"My experience is that as soon as people are old enough to know better, they don't know anything at all." Oscar Wilde
"If a nation values anything more than freedom, it will lose its freedom; and the irony of it is that if it is comfort or money that it values more, it will lose that too." W.Somerset Maugham
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform