sinmetal / til

Today I Learned
MIT License
0 stars 0 forks source link

BigQuery Memo #32

Open sinmetal opened 2 years ago

sinmetal commented 2 years ago

hoge,fuga[FILTERD] に置換する

WITH
  Sample AS (
  SELECT
    "hello:[hoge,fuga],world:[moge]" AS message)
SELECT
  REGEXP_REPLACE(message, r"hello:\[.*?\]", "hello:[[FILTERD]]")
FROM
  Sample