OpenMetadata/bootstrap/sql/migrations/native/1.5.0/postgres/postDataMigrationSQLScript.sql
IceS2 f0049853ec
FIXES 14885: Initial deltalake implementation for s3 (#16665)
* Initial deltalake implementation for s3

* Fix styles

* Fix test_amundsen

* Fix UnitTests

* Fix Checkstyle

* Fix integration tests due to datalake client refactor

* Fix unit tests

* Fix tests

* Fix Integration DeltaLake Storage test

* Skip delta storage integration test for python 3.8

* DeltaLake JSONSchema changes migrations

* Update import name

* Add some comments based on sonarcloud suggestions

* Update DeltaLake documentation

* Resolve some comments
2024-06-20 12:08:21 +05:30

38 lines
1.4 KiB
SQL

-- matchEnum Test Definition Parameter for columnValuesToBeInSet
UPDATE test_definition
SET json = jsonb_set(json, '{parameterDefinition}', json->'parameterDefinition' || '['
'{"name": "matchEnum", "displayName": "Match enum", "description": "If enabled, validate that each value independently matches the enum.", "dataType": "BOOLEAN", "required": false, "optionValues": []}'
']'::jsonb
)
WHERE name = 'columnValuesToBeInSet'
AND JSONB_ARRAY_LENGTH(json->'parameterDefinition') < 2;
-- Test Case dyanic test migration
UPDATE test_definition
SET json = JSONB_SET(json, '{supportsDynamicAssertion}', 'true', true)
WHERE name IN (
'columnValueMaxToBeBetween',
'columnValueMeanToBeBetween',
'columnValueMedianToBeBetween',
'columnValueMinToBeBetween',
'columnValueStdDevToBeBetween',
'columnValuesLengthsToBeBetween',
'columnValuesSumToBeBetween',
'columnValuesToBeBetween',
'tableRowCountToBeBetween'
);
-- Update DeltaLake service due to connection schema changes to enable DeltaLake ingestion from Storage
UPDATE dbservice_entity
SET json = JSONB_SET(
JSONB_SET(
json,
'{connection,config,configSource}',
JSONB_BUILD_OBJECT('connection', json->'connection'->'config'->'metastoreConnection')
),
'{connection,config,configSource,appName}',
json->'connection'->'config'->'appName'
) #- '{connection,config,metastoreConnection}' #- '{connection,config,appName}'
WHERE serviceType = 'DeltaLake';