util

package
v0.7.0 Latest Latest
Warning

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

Go to latest
Published: Feb 18, 2023 License: Apache-2.0 Imports: 17 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var CompactPrimaryCol = compactPrimaryCol
View Source
var CompactSingleIndexCol = compactSingleIndexCol
View Source
var SerialWithCompacted = serialWithCompacted

Functions

func BuildCompositeClusterByColumnName added in v0.7.0

func BuildCompositeClusterByColumnName(s []string) string

func BuildCompositePrimaryKeyColumnName added in v0.6.0

func BuildCompositePrimaryKeyColumnName(s []string) string

func BuildIndexTableName added in v0.6.0

func BuildIndexTableName(ctx context.Context, unique bool) (string, error)

func BuildMoColumnsFilter added in v0.7.0

func BuildMoColumnsFilter(curAccountId uint64) tree.Expr

Build the filter condition AST expression for mo_columns, as follows: account_id = current_id or (account_id = 0 and (att_relname in ('mo_database','mo_tables','mo_columns')))

func BuildMoDataBaseFilter added in v0.7.0

func BuildMoDataBaseFilter(curAccountId uint64) tree.Expr

Build the filter condition AST expression for mo_database, as follows: account_id = cur_accountId or (account_id = 0 and datname in ('mo_catalog'))

func BuildMoTablesFilter added in v0.7.0

func BuildMoTablesFilter(curAccountId uint64) tree.Expr

Build the filter condition AST expression for mo_tables, as follows: account_id = cur_account_id or (account_id = 0 and (relname in ('mo_tables','mo_database','mo_columns') or relkind = 'cluster'))

func BuildUniqueKeyBatch added in v0.6.0

func BuildUniqueKeyBatch(vecs []*vector.Vector, attrs []string, parts []string, originTablePrimaryKey string, proc *process.Process) (*batch.Batch, int)

func ExtractCompositePrimaryKeyColumnFromColDefs added in v0.6.0

func ExtractCompositePrimaryKeyColumnFromColDefs(colDefs []*plan.ColDef) ([]*plan.ColDef, *plan.ColDef)

func FillCompositeClusterByBatch added in v0.7.0

func FillCompositeClusterByBatch(bat *batch.Batch, cbName string, proc *process.Process)

func FillCompositePKeyBatch added in v0.6.0

func FillCompositePKeyBatch(bat *batch.Batch, p *plan.ColDef, proc *process.Process) error

Build composite primary key batch

func GetClusterByColumnOrder added in v0.7.0

func GetClusterByColumnOrder(cbName, colName string) int

func GetClusterTableAttributeName added in v0.7.0

func GetClusterTableAttributeName() string

func GetClusterTableAttributeType added in v0.7.0

func GetClusterTableAttributeType() *tree.T

func IsClusterTableAttribute added in v0.7.0

func IsClusterTableAttribute(name string) bool

func JudgeIsCompositeClusterByColumn added in v0.7.0

func JudgeIsCompositeClusterByColumn(s string) bool

func JudgeIsCompositePrimaryKeyColumn added in v0.6.0

func JudgeIsCompositePrimaryKeyColumn(s string) bool

this func can't judge index table col is compound or not

func SplitCompositeClusterByColumnName added in v0.7.0

func SplitCompositeClusterByColumnName(s string) []string

func SplitCompositePrimaryKeyColumnName added in v0.6.0

func SplitCompositePrimaryKeyColumnName(s string) []string

func SplitTableAndColumn

func SplitTableAndColumn(name string) (string, string)

func TableIsClusterTable added in v0.7.0

func TableIsClusterTable(tableType string) bool

TableIsClusterTable check the table type is cluster table

Types

This section is empty.

Jump to

Keyboard shortcuts

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