diff

package
v0.6.7 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 1, 2026 License: AGPL-3.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ColumnChange

type ColumnChange struct {
	Name string
	Old  *schema.Column
	New  *schema.Column
}

type DataDiff

type DataDiff struct {
	Table   string
	Added   int64
	Removed int64
	Changed int64
}

type Result

type Result struct {
	Schema []TableDiff
	Data   []DataDiff
}

func Compare

func Compare(oldPath, newPath string) (*Result, error)

func CompareSchemas

func CompareSchemas(oldSchema, newSchema *schema.Schema) *Result

CompareSchemas compares two schemas loaded via connectors. Data diff is skipped for remote sources.

type TableDiff

type TableDiff struct {
	Name           string
	Added          bool
	Removed        bool
	AddedColumns   []schema.Column
	RemovedColumns []schema.Column
	ChangedColumns []ColumnChange
	AddedIndexes   []schema.Index
	RemovedIndexes []schema.Index
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL