Solved

Update command giving error where two databases are involved

Posted on 2013-12-30
2
175 Views
Last Modified: 2013-12-30
update ind13.dbo.mstmassstudents
set ind13.dbo.mstmassstudents.ims=ind13i.dbo.mstmassstudents.ims  
from ind13.dbo.mstmassstudents
inner join ind13i.dbo.mstmassstudents on
ind13.dbo.mstmassstudents.uid = ind13i.dbo.mstmassstudents.uid
and ind13.dbo.mstmassstudents.subjectcode  = ind13i.dbo.mstmassstudents.subjectcode
and ind13.dbo.mstmassstudents.course  = ind13i.dbo.mstmassstudents.course
and ind13.dbo.mstmassstudents.semester  = ind13i.dbo.mstmassstudents.semester

I want to update ims field if ind13.dbo.mstmassstudents
from ind13i.dbo.mstmassstudents


Where is an error
0
Comment
Question by:searchsanjaysharma
2 Comments
 
LVL 68

Accepted Solution

by:
Qlemo earned 500 total points
ID: 39746152
To reduce the probability of typos please use aliases:
update i13stud
set ims = i13istud.ims
from ind13.dbo.mstmassstudents i13stud
inner join ind13i.dbo.mstmassstudents i13istud on
i13stud.uid = i13istud.uid
and i13stud.subjectcode  = i13istud.subjectcode 
and i13stud.course  = i13istud.course
and i13stud.semester  = i13istud.semester 

Open in new window

If that still does not work, provide the error message, please.
0
 

Author Closing Comment

by:searchsanjaysharma
ID: 39746170
tx
0

Featured Post

Backup Your Microsoft Windows Server®

Backup all your Microsoft Windows Server – on-premises, in remote locations, in private and hybrid clouds. Your entire Windows Server will be backed up in one easy step with patented, block-level disk imaging. We achieve RTOs (recovery time objectives) as low as 15 seconds.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Long way back, we had to take help from third party tools in order to encrypt and decrypt data.  Gradually Microsoft understood the need for this feature and started to implement it by building functionality into SQL Server. Finally, with SQL 2008, …
This article explains how to reset the password of the sa account on a Microsoft SQL Server.  The steps in this article work in SQL 2005, 2008, 2008 R2, 2012, 2014 and 2016.
This is used to tweak the memory usage for your computer, it is used for servers more so than workstations but just be careful editing registry settings as it may cause irreversible results. I hold no responsibility for anything you do to the regist…
Internet Business Fax to Email Made Easy - With  eFax Corporate (http://www.enterprise.efax.com), you'll receive a dedicated online fax number, which is used the same way as a typical analog fax number. You'll receive secure faxes in your email, f…

867 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

22 Experts available now in Live!

Get 1:1 Help Now