Solved

Help with update query

Posted on 2008-10-30
1
178 Views
Last Modified: 2012-05-05
Please take a look at the attached SQL query. I need to update MASTER6.SSN = secaccessmerge.SSN where L__d__bName matches in both tables AND where MASTER6.Desired__bAction = "Physician'

Do I have the syntax correct? Thanks in advance.
UPDATE MASTER6 INNER JOIN secaccessmerge ON MASTER6.L__d__bName=secaccessmerge.L__d__bName AND MASTER6.Desired__bAction = 'Physician' SET MASTER6.SSN=secaccessmerge.SSN

Open in new window

0
Comment
Question by:isaacr25
1 Comment
 
LVL 39

Accepted Solution

by:
BrandonGalderisi earned 500 total points
Comment Utility
Close...

UPDATE  m
SET SSN=s.SSN
from MASTER6  m
INNER JOIN secaccessmerge  s
  ON m.L__d__bName=s.L__d__bName
  AND m.Desired__bAction = 'Physician'

0

Featured Post

IT, Stop Being Called Into Every Meeting

Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

Join & Write a Comment

Suggested Solutions

Occasionally there is a need to clean table columns, especially if you have inherited legacy data. There are obviously many ways to accomplish that, including elaborate UPDATE queries with anywhere from one to numerous REPLACE functions (even within…
Composite queries are used to retrieve the results from joining multiple queries after applying any filters. UNION, INTERSECT, MINUS, and UNION ALL are some of the operators used to get certain desired results.​
This video discusses moving either the default database or any database to a new volume.
Excel styles will make formatting consistent and let you apply and change formatting faster. In this tutorial, you'll learn how to use Excel's built-in styles, how to modify styles, and how to create your own. You'll also learn how to use your custo…

762 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

10 Experts available now in Live!

Get 1:1 Help Now