'Visual Studio Data Tools - Build Error - SQL71561 xxx contains an unresolved reference to an object. Either the object does not exist

On attempting to build a database project, I am getting the following errors for the view below.

create view [schema].[test]
as
select distinct
    [ai].[account_id] as [service_account]
from
    [linkedserver].[database].[dbo].[view_name] ai
where
    stage = 'start'
and
    srn not in (
    select distinct 
        [ai].[account_id]
    from 
        [linkedserver].[database].[dbo].[view_name] ai
    where stage = 'progressing'
    )

SQL71561: Computed column [schema].[test].[service_account] contains and unresolved reference to an object. Either the object does not exist or hte reference is ambigious becuase it could refer to any of the following objects. [linkedserver].[database].[dbo].[view_name].[account_id] or [linkedserver].[database].[dbo].[view_name].[ai]::[account_id]

I was wondering if anyone has experienced similar errors with Visual Studio 2019 Data Tools

From the research I have done, some others have imported a database reference for the project, but that appears to be for a different type of error.



Solution 1:[1]

I have addressed issue by clear out the "Database variable" field while adding the "Database Reference" would allow 3 parts qualified name.

enter image description here

Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source
Solution 1 Balaganesan Ravichandran