hi,

in a merge replication I use a view (V1) that references another view (V2) in its select statement.

when running the merge agent to initialize the subscriber I get this error:

The schema script '\\SSS-SERVER\ReplData\unc\SSS-SERVER_E5K_714_FS_E5K_714_FS_Replikat\200404072145 58\V1_667.sch' could not be propagated to the subscriber.
(Source: Merge Replication Provider (Agent); Error number: -2147201001)
---------------------------------------------------------------------------------------------------------------
Unable to replicate a view or function because the referenced objects or columns are not present on the Subscriber.
(Source: SSS1 (Agent); Error number: 0)
---------------------------------------------------------------------------------------------------------------
Invalid object name 'dbo.V2'.
(Source: SSS1 (Data source); Error number: 208)
---------------------------------------------------------------------------------------------------------------

I think the error occurs, because V2 is not yet present on the subscriber when the agent tries to create V1. (when i check the views created on the subscriber after the agent fails, V2 is missing)

so how can I tell the agent the order of creating objects?
or is there any other solution?

thanks for your help
thomas