Hi,

I want to make a simple script to move a document from a particular sub-org to another sub org. I wrote it:

UPDATE OnboardingPackage
SET OrganizationId = GTP.OrganizationID
FROM GO_Demo.dbo.OnboardingPackage OP INNER Join GO_Demo.dbo.OnboardingPackage GTP ON GTP.Id = OP.Id
WHERE (GTP.OrganizationId NOT IN ('71E1E177-4621-4AB6-8145-07B506ABDFFC', '7F1BDC6F-CFF9-4181-85F4-AFD223EC51D8'))

but am getting an error:

Msg 8154, Level 16, State 1, Line 1
The table 'OnboardingPackage' is ambiguous.

I've never written one of these before, but I thought it might make my job a bit simpler if I created one.

What am I doing wrong?

Thank you in advance.

Keega