unicode前面没有U +
https://apps.timwhitlock.info/emoji/tables/unicode
unicode前面有一个U +
https://en.wikipedia.org/wiki/Code_point
我不明白维基百科的解释。
似乎所有这一切都是将U +添加到完全有效的十六进制数。为什么?
答案 0 :(得分:3)
这是一种惯例,表示代码点应该被解释为Unicode。
例如,您可能会看到WITH RECURSIVE months(start_date, end_date) AS (
select
timestamp '2017-01-01',/*change this date to adjust range*/
(date_trunc('MONTH', timestamp '2017-01-01') + INTERVAL '1 MONTH')::DATE/*change this date to adjust range*/
UNION ALL
SELECT
start_date + interval '1 month',
(date_trunc('MONTH', start_date + interval '1 month') + INTERVAL '1 MONTH')::DATE
FROM
months
WHERE
start_date < timestamp '2017-12-01' /*change this date to adjust range*/
),
subscription_months(start_date, end_date, user_id) as(
select
months.start_date::DATE,
months.end_date,
initial_subscription.user_id
from
subscription initial_subscription
left join lateral (
select
cancellation.timestamp
from
subscription cancellation
where
cancellation.user_id = initial_subscription.user_id
and cancellation.timestamp >= initial_subscription.timestamp
and cancellation.action = 'unsubscribed'
order by
cancellation.timestamp asc
limit 1
) as cancellation on true
inner join months on
initial_subscription.timestamp <= months.end_date
and (
cancellation.timestamp is null
or cancellation.timestamp >= months.end_date
)
where
initial_subscription.action = 'subscribed'
)
select
start_date,
end_date,
count(distinct user_id)
from
subscription_months
group by
start_date,
end_date
order by
start_date
,但如果没有某些上下文,则您不知道它的含义。 2e2e
提供了该上下文,明确表示它代表“⸮”