MCPcopy Index your code
hub / github.com/cloudquery/cloudquery / createTableNameSchema

Function createTableNameSchema

cli/cmd/sync_v3.go:833–843  ·  view source on GitHub ↗

createTableNameSchema creates a minimal Arrow schema containing only table metadata This schema can be processed through the same transformation pipeline as MigrateTable

(tableName string)

Source from the content-addressed store, hash-verified

831// createTableNameSchema creates a minimal Arrow schema containing only table metadata
832// This schema can be processed through the same transformation pipeline as MigrateTable
833func createTableNameSchema(tableName string) *arrow.Schema {
834 md := arrow.NewMetadata([]string{schema.MetadataTableName}, []string{tableName})
835
836 // Create a minimal schema with one dummy string field
837 return arrow.NewSchema(
838 []arrow.Field{
839 {Name: "_dummy", Type: arrow.BinaryTypes.String},
840 },
841 &md,
842 )
843}
844
845// getTransformedTableNameFromSchema extracts the table name from a transformed schema
846func getTransformedTableNameFromSchema(transformedSchemaBytes []byte) (string, error) {

Callers 1

syncConnectionV3Function · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected