Probl�me de cr�ation de vue index�e : impossible de lier au sch�ma
Bonjour,
Je souhaite indexer une vue pour optimiser son ex�cution.
J'ai un message d'erreur "Impossible de lier au sch�ma vue 'dbo.CLIENT_METROPUB_RE_POINTLEVETOPORESEAU_P'. 'dbo.fZetZprimeTOPO' n'est pas li� au sch�ma."
J'ai bien pr�fix� mes objets par le nom du sch�ma dbo
La vue fait r�f�rence � une fonction. Est-ce autoris�?
Code:
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27
| -- Set the options to support indexed views.
SET NUMERIC_ROUNDABORT OFF
GO
SET ANSI_PADDING, ANSI_WARNINGS, CONCAT_NULL_YIELDS_NULL, ARITHABORT,
QUOTED_IDENTIFIER, ANSI_NULLS ON
GO
-- Create view with SCHEMABINDING.
create view dbo.CLIENT_METROPUB_RE_POINTLEVETOPORESEAU_P
with SCHEMABINDING
as (
select GID
, RS_RE_TRONCON_L
, IDENT
, Z
, PROFONDEUR
, GEOM as geometrie
, GEOM.STAsBinary ( ) as geometrieWKB
, case
when PRECISIONZ is null then 'C'
else PRECISIONZ
end as PRECISIONZ
, CDATE
, MDATE
from dbo.fZetZprimeTOPO ()
) |
Je vous remercie de votre aide