I would like to combine these queries:
UPDATE T1 SET Opening_date = T2.Opening_date FROM FactTransaction T1 INNER JOIN DimStore T2 ON T1.cod_Store = T2.Cod_StoreKey
UPDATE FactTransaction SET ORDINAL = DATEDIFF(DAY, Opening_Date, DATE)
In order to avoid insert the field
Opening_date in my fact table. I don't know how to do it just with a query.