跳到正文
Skillpedia
数据库41k · #6844

adding-warehouse-person-properties

它能做什么

本技能将已同步的数据仓库表中的列映射为 PostHog 中的用户或群组属性。适合把客户信息保存在数据仓库中、并希望在 PostHog 中用于定向和洞察的团队。

适用场景

  • ✓当你想把账单表中的套餐等级或收入添加到用户上时。
  • ✓当你想使用数据仓库中的数据来定向功能开关或人群的时候。
  • ✓当数据仓库中的值没有显示在用户上,你需要查明原因时。

技能链接

https://github.com/PostHog/posthog/blob/master/products/customer_analytics/skills/SKILL.md

复制后粘贴给你的 AI(Claude、ChatGPT 或 Cursor),让它按照说明操作。

使用方法

最简单的方法:复制下面的消息,粘贴给你的 AI。它会读取这个技能并按说明操作。

可直接粘贴的消息

请用这个技能帮我:https://github.com/PostHog/posthog/blob/master/products/customer_analytics/skills/SKILL.md 阅读该链接中的 SKILL.md 文件,并在我的任务中按照它的说明来做。
想让你的 AI 自己找到这样的技能吗?安装免费的 Skillpedia MCP:只需一行,每次任务前它都会在 15,000+ 个技能中搜索。1 分钟完成安装 →

可以这样问 AI

“请把我 Stripe 表中的套餐等级列添加到 PostHog 中的每位用户上,以便我用功能开关对他们进行定向。”

每周 5 个新技能,1 分钟读完。

工作原理

你需要选择源表、匹配的 ID 列,以及要复制的列。随后,PostHog 会把这些列写为普通的用户或群组属性,其使用方式与任何其他属性一样。

技术内容(原始 SKILL.md)

作者在 GitHub 上的英文原文。

Adding warehouse person and group properties

A warehouse property mapping reads a synced warehouse table and writes chosen columns onto people or groups. Each row is matched to a person by a distinct ID column, or to a group by a group key column. The mapped columns are then written as ordinary person properties ($set) or group properties ($groupidentify).

The result is not a separate kind of property. After the first sync the values behave like any other person or group property, so they work in feature flags, cohorts, insights, surveys, and replay filters. See references/where-they-can-be-used.md for the full surface list and the caveats that matter per surface.

In the UI this lives at Data > Warehouse properties, with a Persons tab and a Groups tab.

When to use this skill

  • "Add plan tier from my Stripe table to my people"
  • "I want to run a feature flag only for customers with ARR over 50k"
  • "Sync my Postgres accounts table onto organizations"
  • "Why isn't my warehouse property showing up on people?"
  • "Backfill the warehouse property I just added"

Use a different skill when:

  • The warehouse source does not exist yet. Connect it first with setting-up-a-data-warehouse-source.
  • The user wants a Customer analytics account property. That target reads a materialized view, not a synced table, and uses saved_query + source_column instead of the column map below.
  • The user only wants to query warehouse data. Join it in HogQL instead of writing properties onto people.

Prerequisites

Check these before you start. Each one produces a confusing failure later if it is missing.

Requirement Why How it fails
The warehouse-person-properties feature is enabled for the project Gates the whole feature Definition create rejects a person or group target; sync and backfill return 400
A synced warehouse table Only tables imported by a data warehouse source carry the schema a source binds to Views, saved queries, and materialized views cannot be used for person or group targets
A column holding a real person distinct_id, or a real group key Rows are matched on this column Runs complete with a high skipped_missing_person count and no properties change
The caller has warehouse source editor access Mapping a table drives its billable source Create is rejected even when the caller holds account:write
For group targets: the groups paid feature, an existing group type, and group:read / group:write Group properties are keyed per group type The Groups tab is hidden; group tools reject the call

Tools

Tool Purpose
external-data-schemas-list Find the table and its schema id. The schema id is what a source binds to
query (HogQL) Inspect columns and sample the key column before you map anything
custom-property-definitions-create Create the mapping's definition with target_type of person or group
custom-property-sources-create Bind the definition to the warehouse table and column map
custom-property-sources-list / -retrieve See sync status, schedule, and the latest run
常见问题

我需要先连接数据仓库源吗?

需要。该数据源必须已经存在并处于同步状态。连接数据源是单独的步骤。

这些属性可以在哪些地方使用?

凡是用户和群组属性可以使用的地方都可以,例如功能开关、人群、洞察、问卷和工作流。

这些值会自动更新吗?

会,按源表同步的计划进行更新。

详情

作者的原始描述

Sync columns from a synced data warehouse table onto PostHog person or group properties, so warehouse data becomes usable anywhere person and group properties already work: feature flag targeting, cohorts, insight filters and breakdowns, surveys, session replay filters, workflows, and the person profile. Use when the user wants to "add a person property from my warehouse", "enrich people with Stripe/Postgres/Salesforce data", "put ARR or plan tier on my persons", "target a feature flag by a warehouse column", "sync warehouse columns onto groups or organizations", or wants to inspect, backfill,

repo: PostHog/posthog

热度

GitHub 星标
41k
排名
#6844
许可证
—
更新时间
2026/11/2

这个技能有用吗?

0

登录 后即可投票。

评论

  • …

同一仓库的更多技能

相似技能