Skip to main content
Custom approval flows require Enterprise. Plans and their linked Issues also exist without this feature; in that case, review requires no human approval.
A Plan manages a database change throughout its lifecycle: SQL and targets, checks, review, and deployment. In the UI workflow, its linked Issue records review and its Rollout tracks execution. Submitting for review does not convert the Plan into an Issue. This page covers UI Plan authoring. Follow the UI tutorial for a complete example, or the GitOps tutorial for Release-based Plans.

1. Create Plan

In your project, navigate to CI/CD > Plans and click + New Plan.

2. Select Databases

Choose one or more target databases and click Confirm.

3. Add Changes

Enter SQL for the selected targets. Use Add Change for another change with its own SQL and targets. Click Create to save a draft Plan and its linked draft Issue. Bytebase runs automated checks; the SQL has not executed yet. bb-plan-warning-detail

4. Submit for Review

Inspect the checks, correct errors, and assess warnings. Click Ready for Review to submit the linked Issue. The Plan remains the page for managing the change. Approval follows configured rules; if no human approval is required, the approval flow says No approval required. The plan detail page shows a Review section where you can follow the approval flow and the activity timeline while the change awaits approval. Review section on the plan detail page showing the pending approval flow and activity timeline

Comment on statement lines

Once the Issue is submitted for review, members holding the Project Owner, Developer, Releaser, or Viewer role can comment on specific lines of the SQL in the plan’s statement editor. Select one or more lines in the gutter and click the comment glyph on the last selected line, or right-click and choose Comment on lines. Write the comment and click Publish. This starts a thread: others can Reply, and anyone with one of those roles can Resolve or Reopen it. Threads appear inline in the editor and as cards in Review Activity. Inline comment thread on line 2 of the SQL in the plan statement editor, with the Reply box, Resolve button, and unresolved-thread counter
  • A counter above the editor shows how many threads are still unresolved on the current version, with Previous unresolved thread and Next unresolved thread arrows to step through them.
  • When the SQL is edited, a thread stays on its lines if they did not change. A thread on a line that changed or was deleted is marked Outdated: it leaves the editor but stays in Review Activity.
  • Replying to a resolved thread reopens it unless you clear Reopen thread in the reply box.
  • Comments attach to a change’s SQL, so in a Plan with several changes each change has its own threads, shared by all of that change’s target databases. Create-database specs cannot be commented on.

5. Deploy

Once approval is satisfied and checks finish without errors, Bytebase automatically creates the Rollout. Follow execution in Deploy. Manual environments wait for an authorized user to click Run; automatic environments follow their Rollout Policy. bb-issue-2-targets-to-rollout Deploy to Test first, then Prod after success.