locked
validating version problem RRS feed

  • Question

  • I got a problem in validating version. After click the validate version button and clicking "ok", the page just reloads and nothing more. I am using an admin account in doing the validation. I wonder what is the problem. The status is already "Locked" before hitting the validate version button.

    I hope someone can help me with this.

    Monday, October 10, 2011 2:11 AM

Answers

  • Hi BBernabe

    it looks like a data issue

    do you have a flag assigned to a version ?

    did you activate the mds trace / SSMS profiler ?

    you can also try to execute the code of stored procedure mdm.udpValidatemodel in SSMS and get error details

    code of this sp is: (you'll have to set the proper values for User_ID,Model_ID,Version_ID)

     

    Status_ID =3 --> Commit
    User_ID --> default = 1 for administrator

     

     

     declare @User_ID INT SET @User_ID= 1
      declare @Model_ID INT set @Model_ID = yourmodelid
      declare @Version_ID INT set @Version_ID = yourversionid
      declare @Status_ID INT  set @Status_ID = 3
      
    	EXEC mdm.udpSystemEventSave @User_ID,@Version_ID,'ValidateModel',1  
      
    	DECLARE @MetaID		INT;  
    	DECLARE @EntityID	INT;  
    	DECLARE	@Entities   TABLE (EntityID int,ProcessSeq int);  
      
    	--Determine processing sequence of entities based on entity dependency.  
    	INSERT INTO @Entities  
            SELECT   
                  Entity_ID  
                 ,[Level]  
            FROM mdm.udfEntityGetProcessingSequence(@Model_ID)  
            ORDER BY [Level]  
    		  
    	DECLARE @CurrentStatus_ID TINYINT  
    	DECLARE @Counter INT = 1;  
    	DECLARE @MaxCounter INT = (SELECT MAX(ProcessSeq) FROM @Entities);  
      
    	WHILE @Counter <= @MaxCounter  
    	BEGIN  
    		SELECT @EntityID = EntityID FROM @Entities WHERE ProcessSeq = @Counter;  
        	EXEC mdm.udpValidateEntity @User_ID, @Version_ID, @EntityID  
        	  
    		SELECT @CurrentStatus_ID = EventStatus_ID FROM mdm.tblEvent E WHERE E.LastChgUserID = @User_ID AND EventName = CAST(N'ValidateModel' AS NVARCHAR(100)) AND Version_ID = @Version_ID  
    		  
    		IF @CurrentStatus_ID = 2 --Canceled  
    			SET @Counter = @MaxCounter + 1;  
    		ELSE  
                SET @Counter += 1;  
    	END -- WHILE  
      
    	EXEC mdm.udpSystemEventSave @User_ID,@Version_ID,N'ValidateModel',2  
      
    	IF @Status_ID = 3 --Commit  
    	   BEGIN  
    		  IF NOT EXISTS(SELECT 1 FROM mdm.viw_SYSTEM_ISSUE_VALIDATION WHERE Version_ID = @Version_ID)  
    			 BEGIN  
    				EXEC mdm.udpVersionSave @User_ID,@Model_ID,@Version_ID,null,3,NULL,NULL,NULL  
    			 END  
    	   END  
      
    
    Regards,

     



    Xavier Averbouch
    Microsoft Community Contributor
    Avanade , FRANCE
    If a post answers your question, please click "Mark As Answer" on that post and "Vote as Helpful".
    Tuesday, October 11, 2011 8:51 AM