Wildcards in table mapping - excluding `_`

0

I want to exclude several tables (Aurora Postgres) from DMS replication. All the tables I want to exclude have suffixes __f or __b. Where _ is special char for DMS table mappings. I try to use regex as :

  • %#_#_b
  • %[_][_]b

None of the above is working for me.

Example of my mapping rule:

{
       "object-locator": {
           "schema-name": "%",
           "table-name": "%[_][_]b"
       },
       "rule-action": "exclude",
       "rule-id": "1",
       "rule-name": "exclude_b",
       "rule-type": "selection"

},

Kamil M
質問済み 9ヶ月前422ビュー
1回答
0

Hi, I am afraid that '%' is greedy here: it eats all characters up to the end including the suffixes that you are looking for.

So, you may want to try something like _______[_][_]b with _______ matching the exact number of chars of 1 of your tables with suffix _b to exclude to confirm the greedyness of %.

If confirmed, you can create such an exclusion rule for all possible name lengths of your use case. Yes, I know that it it not elegant but at least it's a workaround. In parallel, I would open a ticket with AWS Support to see if they have a better solution or can fix the greedyness of %.

Best,

Didier

profile pictureAWS
エキスパート
回答済み 9ヶ月前

ログインしていません。 ログイン 回答を投稿する。

優れた回答とは、質問に明確に答え、建設的なフィードバックを提供し、質問者の専門分野におけるスキルの向上を促すものです。

質問に答えるためのガイドライン

関連するコンテンツ