---
id: SCR-PFM-QRY-018
title: Custom query table detail (Rhythm HQ)
route: '/hq/customQueryTables/{id}'
surface: console
product_area: platform
module: queries
revision: 1
status: draft
design_intent: proposed
implementation_evidence: observed
inference: []
source_sha:
  react-console: baf6dae382d6f41dce976c7f848667ccc37e076f
  services-platform: ad3f6a6582843008ed0f5a17b131878d15829af1
purpose: >-
  Let authorized Rhythm staff edit, analyze, preview, publish and assign a custom-table definition
  while inspecting its usage and history.
supports:
  - CAP-PFM-QRY-005
permission: >-
  hq.custom-query-tables.read; drafting and preview .author; publishing and lifecycle .publish;
  assignments .assign
entry_from:
  - Custom query table library
exits_to:
  - Custom query table library
displays:
  - field: 'Definition, draft, selected release, assignments and validation health.'
    source: getCustomQueryTable
  - field: 'Read sources, derived grants, canonical SQL and located analysis problems.'
    source: analyzeCustomQueryTableDraft
  - field: Version output fields and recorded breaking changes.
    source: 'listCustomQueryTableVersions, getCustomQueryTableVersion'
  - field: Workspace-grouped saved-query dependencies.
    source: getCustomQueryTableUsage
  - field: Retained authoring and availability-change history.
    source: listCustomQueryTableEvents
actions:
  - label: Save draft
    operation_id: saveCustomQueryTableDraft
    permission: hq.custom-query-tables.author
    confirm: false
  - label: Edit identity
    operation_id: updateCustomQueryTable
    permission: hq.custom-query-tables.author
    confirm: false
  - label: Preview
    operation_id: previewCustomQueryTable
    permission: hq.custom-query-tables.author
    confirm: false
  - label: Publish
    operation_id: publishCustomQueryTable
    permission: hq.custom-query-tables.publish
    confirm: true
  - label: Add an Assignment
    operation_id: assignCustomQueryTable
    permission: hq.custom-query-tables.assign
    confirm: false
  - label: Pin version
    operation_id: pinCustomQueryTableAssignment
    permission: hq.custom-query-tables.assign
    confirm: false
  - label: Remove Assignment
    operation_id: unassignCustomQueryTable
    permission: hq.custom-query-tables.assign
    confirm: true
  - label: Deprecate
    operation_id: deprecateCustomQueryTable
    permission: hq.custom-query-tables.publish
    confirm: true
  - label: Disable
    operation_id: disableCustomQueryTable
    permission: hq.custom-query-tables.publish
    confirm: true
  - label: Restore
    operation_id: restoreCustomQueryTable
    permission: hq.custom-query-tables.publish
    confirm: true
  - label: Revalidate now
    operation_id: revalidateCustomQueryTables
    permission: hq.custom-query-tables.publish
    confirm: false
states:
  - definition loading
  - no released version
  - analysis needs repair
  - breaking dependencies need acknowledgement
  - validation workspace unavailable
  - definition deprecated
  - definition disabled
  - stale write conflict
validation:
  - BR-CAP-PFM-QRY-005-03
  - BR-CAP-PFM-QRY-005-04
  - BR-CAP-PFM-QRY-005-05
  - BR-CAP-PFM-QRY-005-06
  - BR-CAP-PFM-QRY-005-09
  - BR-CAP-PFM-QRY-005-10
  - BR-CAP-PFM-QRY-005-14
  - BR-CAP-PFM-QRY-005-16
patterns:
  - Rhythm HQ Full layout
  - 'tabs (definition, columns, validation, versions, usage, history)'
  - SQL field
  - publish dialog with acknowledgements
  - assignments sheet
  - lifecycle dialog with reason
component: components/custom-query-tables/custom-table-editor.tsx and its tabs and dialogs
evidence:
  - >-
    react-console at baf6dae: app/(console)/hq/customQueryTables/[id]/page.tsx;
    components/custom-query-tables/*.tsx
controls: [TC-AVL-001, TC-AVL-005, TC-AZ-001, TC-AZ-002, TC-AZ-003, TC-AZ-004, TC-AZ-005, TC-AZ-006, TC-CRY-001, TC-CRY-002, TC-CRY-003, TC-CRY-004, TC-IAM-001, TC-IAM-002, TC-IAM-003, TC-IAM-004, TC-IAM-005, TC-LOG-001, TC-LOG-002, TC-LOG-003, TC-LOG-004, TC-LOG-005, TC-MON-001, TC-PI-001, TC-PI-003, TC-PI-005, TC-TEN-001, TC-TEN-002, TC-TEN-003, TC-VEN-001, TC-VEN-002, TC-VEN-003]
---

# Custom query table detail (Rhythm HQ)

## What the Screen Is For

Let authorized Rhythm staff edit, analyze, preview, publish and assign a custom-table definition while inspecting its usage and history.

## What It Shows and Lets People Do

Tabs and dialogs separate identity edits, SQL drafting, preview, publication and assignment. Publish requires current analysis and explicit breaking acknowledgements. Lifecycle actions alter availability independently of released versions; revalidation is available only with validation configuration.

## States and Errors

Invalid SQL remains a draft problem rather than an executable release. Missing validation configuration makes analysis, preview and publication unavailable; stale versions conflict with a newer author’s write.

## Patterns It Must Respect

The full-width staff PageLayout uses the SQL field, source and column tabs, release acknowledgements, assignment sheet and reasoned lifecycle dialog.
