As Dan says, this could be achieved doing SQL queries directly to the database. After connecting to the AtoM database:
mysql> SELECT id, identifier FROM accession WHERE identifier in ('2017-09-14/8','2017-09-14/6');
+---------+--------------+
| id | identifier |
+---------+--------------+
| 2001245 | 2017-09-14/6 |
| 2001248 | 2017-09-14/8 |
+---------+--------------+
2 rows in set (0.00 sec)
- Create the object row and get its id:
mysql> INSERT INTO object (class_name, created_at, updated_at) VALUES ('QubitRelation', NOW(), NOW());
Query OK, 1 row affected (0.03 sec)
mysql> SELECT id FROM object WHERE class_name='QubitRelation' ORDER BY id DESC LIMIT 1;
+---------+
| id |
+---------+
| 2001250 |
+---------+
1 row in set (0.00 sec)
- Create the relation rows, to make '2017-09-14/8' an accrual to '2017-09-14/6':
mysql> INSERT INTO relation (id, object_id, subject_id, type_id, source_culture) VALUES (2001250, 2001245, 2001248, 175, 'en');
Query OK, 1 row affected (0.01 sec)
mysql> INSERT INTO relation_i18n (id, culture) VALUES (2001250, 'en');
Query OK, 1 row affected (0.01 sec)
Accruals are not involved in the Elasticsearch index for accessions, so there is no need to rebuild the search index nor restart any service.
Best regards.