DEV Community

HerrKiel
HerrKiel

Posted on

Build error SQL46005: Expected FILESTREAM_ON but encountered object instead

I am trying to build a database project with azure synapse sql pool as the target database but i get Build error SQL46005: Expected FILESTREAM_ON but encountered object instead error every time single.
I investigated as noticed there are couple procedures where I am using the data swapping approach to stage and load the data. Here is an example of the pattern;

CREATE PROC [schema].[some_proc] AS

-- Drop temp table if exists
if object_id(N'schema.t_dim_temp_table') is not null
drop table schema.t_dim_temp_table;

create table schema.t_dim_temp_table
with (   distribution = hash (somecol)
        ,clustered columnstore index
     )
as
select
*
,CURRENT_TIMESTAMP AS last_update_date
from stgschema.v_dim_stage

-- Rename and remove temp objects
rename object schema.t_dim_table            to schema.t_dim_table_old;
rename object schema.t_dim_temp_table       to schema.t_dim_table;
drop table schema.t_dim_table_old;
Enter fullscreen mode Exit fullscreen mode

Any ideas about how to get around this error will be appreciated

Top comments (0)