# US 10,503,727 B2 · System and method for mapping database changes

> Agents: this data is available as JSON from the patentgrep API and MCP server — see https://patentgrep.com/llms.txt

- Number: US 10,503,727 B2
- Document ID: US10503727B2
- Status: Granted
- Kind: B2
- Application number: 15/487,224
- Filed: 2017-04-13
- Published: 2017-10-26
- Granted: 2019-12-10
- Earliest claimed: 2016-04-26
- Assignees: ServiceNow, Inc.
- Applicants: ServiceNow, Inc.
- Inventors: Jared Laethem; Anson Barber Mayers
- Web page: https://patentgrep.com/patent/US10503727B2

## CPC

- G06F 16/2379: {Updates performed during online database operations; commit processing}
- G06F 8/65: Updates (security arrangements therefor G06F21/57)
- G06F 9/44505: {Configuring for program initiating, e.g. using registry, configuration files}
- G06F 16/1873: {Versioning file systems, temporal file systems, e.g. file system supporting different historic versions of files}
- G06F 16/2365: {Ensuring data consistency and integrity}
- G06F: ELECTRIC DIGITAL DATA PROCESSING (computer systems based on specific computational models G06N)

## Abstract

Software updates that cause changes to a database accessible by software can be identified. A first database can be modified using first instructions associated with a first software update to generate a first modified database, and a second database can be modified using second instructions associated with a second software update to generate a second modified database. A difference between the first and second modified databases can be determined, and one or more instructions of the first or second instructions that caused the difference can be identified based on the difference. The first and second instructions can be converted into operations that, when performed against the first and second databases, result in first and second many-to-many tables being generated. The many-to-many tables can be queried to identify the operations associated with the difference between the first and second modified databases.

## Claims

### Claim 1

A method for identifying updates to software that cause changes to databases accessible by the software, the method comprising:
modifying a database storing data associated with a software application, wherein modifying the database comprises using first instructions associated with a first software update to the software application to generate a first modified database;
modifying the database using second instructions associated with a second software update to the software application to generate a second modified database;
generating a many-to-many table, wherein the many-to-many table maps one or more records in the database that were changed based on the first and second instructions, wherein the many-to-many table comprises information associated with respective application files from which the first software update and the second software update originated;
determining a difference between the first modified database and the second modified database; and
identifying, based on the difference, one or more instructions of the first instructions or the second instructions that caused the difference.

### Claim 2 (depends on 1)

The method of claim 1, wherein modifying the database using instructions associated with a software update to generate a modified database comprises:
converting the instructions into one or more operations performed against at least one of the software or the database,
wherein the database is modified responsive to performing at least some of the one or more operations.

### Claim 3 (depends on 2)

The method of claim 2,
wherein entries of the many-to-many table are associated with respective ones of the at least some of the one or more operations.

### Claim 4 (depends on 3)

The method of claim 3, wherein a first many-to-many table is generated based on at least one of the one or more operations performed to generate the first modified database and a second many-to-many table is generated based on at least one of the one or more operations performed to generate the second modified database, and wherein identifying the one or more instructions of the first instructions or the second instructions that caused the difference comprises:
querying the first many-to-many table and the second many-to-many table for entries associated with the difference,
wherein the entries associated with the difference indicate an operation that caused the difference, wherein the operation is converted from at least one of the first instructions or the second instructions, and
wherein the difference indicates any of a database record, a database field value, and a database structural element that differs between the first modified database and the second modified database.

### Claim 5 (depends on 3)

The method of claim 3, the method comprising:
excluding, from the many-to-many table, data associated with ignored tables of the database.

### Claim 6 (depends on 1)

The method of claim 1, the method comprising:
determining functional equivalence between a first database record of the first modified database and a second database record of the second modified database,
wherein the first database record and the second database record are identical, and wherein database field values stored within the first database record and database field values stored within the second database record are not identical.

### Claim 7 (depends on 1)

The method of claim 1, the method comprising:
determining a first count indicative of a first number of database records that differ between the first modified database and the second modified database;
determining a second count indicative of a second number of database field values that differ between the first modified database and the second modified database; and
determining a third count indicative of a third number of database records storing database field values that differ between the first modified database and the second modified database, wherein an error is indicated responsive to an inconsistency between the first count, the second count, and the third count.

### Claim 8 (depends on 1)

The method of claim 1, wherein the first modified database and the second modified database are identical before being modified.

### Claim 9

A system for identifying updates to software that cause changes to databases accessible by the software, the system comprising:
a memory configured to store one or more processor-executable routines; and
a processor configured to communicate with the memory and to execute the routines stored therein, wherein the routines, when executed, cause the system to:
modify a database storing data associated with a software application, wherein modifying the database comprises using first instructions associated with a first software update to the software application to generate a first modified database;
modify the database using second instructions associated with a second software update to the software application to generate a second modified database;
generate a many-to-many table, wherein the many-to-many table maps one or more records in the database that were changed based on the first and second instructions, wherein the many-to-many table comprises information associated with respective application files from which the first software update and the second software update originated;
determine a difference between the first modified database and the second modified database; and
identify, based on the difference, one or more instructions of the first instructions or the second instructions that caused the difference.

### Claim 10 (depends on 9)

The system of claim 9, wherein the routines to modify the database using instructions associated with a software update to generate a modified database, when executed, cause the system to:
convert the instructions into one or more operations to be performed against at least one of the software or the database,
wherein the database is modified responsive to a performance of at least some of the one or more operations.

### Claim 11 (depends on 10)

The system of claim 10,
wherein entries of the many-to-many table are associated with respective ones of the at least some of the one or more operations.

### Claim 12 (depends on 11)

The system of claim 11, wherein a first many-to-many table is generated based on at least one of the one or more operations performed to generate the first modified database and a second many-to-many table is generated based on at least one of the one or more operations performed to generate the second modified database, and wherein the routines to identify the one or more instructions of the first instructions or the second instructions that caused the difference, when executed, cause the system to:
query the first many-to-many table and the second many-to-many table for entries associated with the difference,
wherein the entries indicate an operation that caused the difference, wherein the operation is converted from at least one of the first instructions or the second instructions, and
wherein the difference indicates any of a database record, a database field value, and a database structural element that differs between the first modified database and the second modified database.

### Claim 13 (depends on 11)

The system of claim 11, wherein the routines, when executed, cause the system to:
exclude, from the many-to-many table, data associated with ignored tables of the database.

### Claim 14 (depends on 9)

The system of claim 9, wherein the routines, when executed, cause the system to:
determine functional equivalence between a first database record of the first modified database and a second database record of the second modified database,
wherein the first database record and the second database record are identical, and wherein database field values stored within the first database record and database field values stored within the second database record are not identical.

### Claim 15 (depends on 9)

The system of claim 9, wherein the routines, when executed, cause the system to:
determine a first count indicative of a first number of database records that differ between the first modified database and the second modified database;
determine a second count indicative of a second number of database field values that differ between the first modified database and the second modified database; and
determine a third count indicative of a third number of database records storing database field values that differ between the first modified database and the second modified database, wherein an error is indicated responsive to an inconsistency between the first count, the second count, and the third count.

### Claim 16 (depends on 9)

The system of claim 9, wherein the first modified database and the second modified database are identical before being modified.

### Claim 17

A method, comprising:
generating a second database from a first database based on instructions associated with one or more software updates to a software application, wherein the one or more software updates modify the first database using the instructions associated with the one or more software updates;
generating a table, wherein the table maps one or more records in the first database that were changed based on the instructions, wherein the table comprises information associated with respective application files from which the one or more software updates update originated;
determining a plurality of differences between the first database and the second database; and
determining which respective instruction of the instructions caused the plurality of differences between the first database and the second database.

### Claim 18 (depends on 17)

The method of claim 17, wherein generating the second database from the first database based on the instructions associated with the one or more software updates comprises:
modifying the first database using first instructions associated with a first software update of the one or more software updates to generate the second database.

### Claim 19 (depends on 18)

The method of claim 18, wherein determining that at least some of the instructions are associated with the plurality of differences between the first database and the second database comprises:
comparing the first database and the second database to determine the plurality of differences; and
querying the table for entries associated with the plurality of differences.

### Claim 20 (depends on 17)

The method of claim 17, the method comprising:
generating a third database from the first database based on other instructions associated with the one or more software updates, wherein the one or more software updates modify the first database using the other instructions associated with the one or more software updates; and
determining which respective instruction of the other instructions caused the plurality of differences between the second database and the third database.
