convert access 2007 sql to sql 2008

I need help re-writing this access 2007 sql query to sql 2008 syntax.

File is attached.
test.txt
DaneanAsked:
Who is Participating?
 
ramromConnect With a Mentor consultant Commented:
Changes for readability:
- reformatted into several lines
- used table aliases
- removed all unnecessary () and []

Since I don't have SQL Server to test this on here is my best guess for the other changes:
- " to '
- date constant following http://msdn.microsoft.com/en-us/library/ms180878%28v=sql.105%29.aspx#StringLiteralDateandTimeFormats
UPDATE CLAIMVIEW AS V
LEFT JOIN P AS P
ON V.SSNO = P.SSNO 
AND V.COMPANY = P.COMPANY 

SET P.COMPANY = V.COMPANY, 
P.SSNO = V.SSNO, 
P.PROBLEM = V.DIAGNOSIS, 
P.REPORTED = V.ENTRYDATE, 
P.STARTDATE = V.ENTRYDATE, 
P.ICD9 = V.ICD9, 
P.RANK = '1', 
P.ENDDATE = '1900-1-1T00:00:00', 
P.PROVIDER = 'MEDINFO', 
P.PROV = 'MEDINFO', 
P.ACCIDENT = 'N', 
P.ENTRYDATE = V.ENTRYDATE

WHERE V.XACDATE > '2011-10-07T00:00:00' 
And V.XACDATE < '2012-08-2407T00:00:00';

Open in new window

0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.