<?xml version="1.0" encoding="UTF-8"?>
<changelog xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="./schema.xsd">
    <changeset id="FS-2257_create_columbia_audience_profile_craig_markman:1" author="ozhovnuvatyi">
        <cypherquery>
          <![CDATA[
            MATCH (identity:Identity {email: 'craig.markman@sonymusic.com'})
            MERGE (increment:IncrementId {nodeName: 'Profile'})
                ON CREATE SET increment.id = 2
                ON MATCH SET increment.id = increment.id + 1
            CREATE (profile:Profile {
                profileId: (increment.id-1),
                profileType: 'AudienceProfile',
                profileName: 'Craig Markman',
                roles: ['audience'],
                fullCatalogAccess: false,
                uuid: apoc.create.uuid(),
                createdAt: datetime(),
                lastModifiedAt: datetime(),
                createdBy: 'https://theorchard.atlassian.net/browse/FS-2257',
                updatedBy: 'https://theorchard.atlassian.net/browse/FS-2257'
            })
            MERGE (identity)-[:HAS_PROFILE]->(profile)
            WITH profile
            MATCH (v:Vendor {id: 34514})
            MERGE (profile)-[:HAS_ACCESS_TO]->(v)
          ]]>
        </cypherquery>
    </changeset>
</changelog>
