Saturday, 1 October 2011

Error on Initialize-AXModelStore –Drop

If you're playing around with Initialize-AXModelStore in the AX database from pre-release of AX2012, you might hit error when trying to drop a schema.

Eg.
You created a model stored schema with Initialize-AXModelStore -AOSAccount "Domain\AccountName" -SchemaName <newschema> -Server <servername> -Database <databasename>
Then when you run Initialize-AXModelStore –Drop <schemaname>, you hit error claiming the XU_DropSchema does not exist.

It is simply because the pre-release database doesn't have the required stored procedure to drop the schema.


All you need to do is
  1. Gnerate CREATE script for XU_DropSchema from the new model store schema you just created
     
  2. Change the stored procedure name to [dbo].[XU_DropSchema], execute it
  3. Then rerun the Initialize-AXModelStore –Drop

No comments:

Post a Comment