diff --git a/pkg/resources/warehouse.go b/pkg/resources/warehouse.go index 024d8ee15d..2737e6c6e2 100644 --- a/pkg/resources/warehouse.go +++ b/pkg/resources/warehouse.go @@ -222,9 +222,12 @@ func ReadWarehouse(d *schema.ResourceData, meta interface{}) error { if err = d.Set("enable_query_acceleration", w.EnableQueryAcceleration); err != nil { return err } - if err = d.Set("query_acceleration_max_scale_factor", w.QueryAccelerationMaxScaleFactor); err != nil { - return err + if w.EnableQueryAcceleration { + if err = d.Set("query_acceleration_max_scale_factor", w.QueryAccelerationMaxScaleFactor); err != nil { + return err + } } + log.Printf("[DEBUG] warehouse type is: %s", w.WarehouseType) if w.WarehouseType == "STANDARD" || w.WarehouseType == "SNOWPARK-OPTIMIZED" { err = d.Set("warehouse_type", w.WarehouseType)