From ad8ea19e8ca71c9e15e89eaa2e0cce6bec002105 Mon Sep 17 00:00:00 2001 From: Nazar Kovtun Date: Mon, 31 Mar 2025 13:44:25 +0300 Subject: [PATCH 1/2] HCK-10529: updated adapter to properly handle hasMaxLength on char --- polyglot/adapter.json | 40 +++++++++++++++++++++ polyglot/convertAdapter.json | 70 ++++++++++++++++++++++++++++++++++++ 2 files changed, 110 insertions(+) create mode 100644 polyglot/convertAdapter.json diff --git a/polyglot/adapter.json b/polyglot/adapter.json index 19bb2cc..382e077 100644 --- a/polyglot/adapter.json +++ b/polyglot/adapter.json @@ -108,6 +108,46 @@ "to": { "mode": "point" } +<<<<<<< Updated upstream +======= + }, + { + "from": { + "type": "varchar", + "hasMaxLength": true + }, + "to": { + "length": 21844 + } + }, + { + "from": { + "type": "varchar", + "mode": "char", + "hasMaxLength": true + }, + "to": { + "length": 255 + } + }, + { + "from": { + "type": "nvarchar", + "hasMaxLength": true + }, + "to": { + "length": 21844 + } + }, + { + "from": { + "type": "binary", + "hasMaxLength": true + }, + "to": { + "length": 21844 + } +>>>>>>> Stashed changes } ] } diff --git a/polyglot/convertAdapter.json b/polyglot/convertAdapter.json new file mode 100644 index 0000000..94a1704 --- /dev/null +++ b/polyglot/convertAdapter.json @@ -0,0 +1,70 @@ +/** + * + * { + * "add": { + * "entity": [], + * "container": [], + * "model": [], + * "view": [], + * "field": { + * "": [] + * } + * }, + * "delete": { + * "entity": [], + * "container": [], + * "model": [], + * "view": [], + * "field": { + * "": [] + * } + * }, + * "modify": { + * "entity": [ + * { + * "from": { }, + * "to": { } + * } + * ], + * "container": [], + * "model": [], + * "view": [], + * "field": [] + * }, + * } + */ + { + "modify": { + "field": [ + { + "from": { + "childType": "char", + "mode": "varchar", + "length": 21844 + }, + "to": { + "hasMaxLength": true + } + }, + { + "from": { + "childType": "char", + "mode": "char", + "length": 255 + }, + "to": { + "hasMaxLength": true + } + }, + { + "from": { + "mode": "varbinary", + "length": 21844 + }, + "to": { + "hasMaxLength": true + } + } + ] + } +} \ No newline at end of file From 90d5112496914fe1f140349b08dbd40448acfd01 Mon Sep 17 00:00:00 2001 From: Nazar Kovtun Date: Mon, 31 Mar 2025 13:46:57 +0300 Subject: [PATCH 2/2] HCK-10529: remove markers --- polyglot/adapter.json | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/polyglot/adapter.json b/polyglot/adapter.json index 382e077..457537c 100644 --- a/polyglot/adapter.json +++ b/polyglot/adapter.json @@ -108,8 +108,7 @@ "to": { "mode": "point" } -<<<<<<< Updated upstream -======= + }, { "from": { @@ -147,7 +146,6 @@ "to": { "length": 21844 } ->>>>>>> Stashed changes } ] }