Validate data in the database

The MDrivenServer has a built-in feature to check for database consistency.

  • Log in to the MDrivenServer
  • Go to Settings->Admin

There are two buttons there:

  1. Validate Admin DB Data
  2. Validate A0DB Data

Admin DB is the database internal of the MDrivenServer containing model information.

A0DB is the internal or external database containing the application data.

Click to run a check on all the tables in the databases.

You will get an error report and an SQL statement to run to see the problem data:

Single link dupes(38146711), execute 
select PublisherAgreementPeriodID,Count(PublisherAgreementPeriodID) from AgreementImport where not PublisherAgreementPeriodID is null group by PublisherAgreementPeriodID having Count(PublisherAgreementPeriodID)>1

Copy the SQL command to your SQL server query interface, find the offending object, and decide what to do.

Most likely, you may want to delete the row - but then, you would have to manually remove all references to that row. Otherwise, you will create new problems, so using SQL to delete things can be tricky.

We suggest you set the link attribute creating the problem to null (thus removing the duplicate problem) and then use the OCL debugger to delete the object. In the debugger, you can use OCL or OclPS to find the (now disconnected) object and delete it. It will then correctly delete any linked aggregate objects, links from other objects to it, and link objects.

This page was edited 68 days ago on 02/10/2024. What links here