github.com/chnsz/golangsdk@v0.0.0-20240506093406-85a3fbfa605b/openstack/dli/v1/tables/results.go (about) 1 package tables 2 3 type CommonResp struct { 4 IsSuccess bool `json:"is_success"` 5 Message string `json:"message"` 6 } 7 8 type DeleteResp struct { 9 CommonResp 10 JobMode string `json:"job_mode"` 11 } 12 13 type ListResp struct { 14 IsSuccess bool `json:"is_success"` 15 Message string `json:"message"` 16 TableCount int `json:"table_count"` 17 Tables []Table4List `json:"tables"` 18 } 19 20 // If with-detail is set to false in the URI, only values of tables-related parameters data_location, table_name, 21 // and table_type are returned. 22 type Table4List struct { 23 CreateTime int `json:"create_time"` 24 DataType string `json:"data_type"` 25 DataLocation string `json:"data_location"` 26 LastAccessTime int `json:"last_access_time"` 27 Location string `json:"location"` 28 Owner string `json:"owner"` 29 TableName string `json:"table_name"` 30 TableSize int `json:"table_size"` 31 PartitionColumns []string `json:"partition_columns"` 32 PageSize int `json:"page-size"` 33 CurrentPage int `json:"current-page"` 34 // Type of a table. 35 // EXTERNAL: Indicates an OBS table. 36 // MANAGED: Indicates a DLI table. 37 // VIEW: Indicates a view. 38 TableType string `json:"table_type"` 39 } 40 41 type Table struct { 42 IsSuccess bool `json:"is_success"` 43 Message string `json:"message"` 44 ColumnCount int `json:"column_count"` 45 Columns []Column `json:"columns"` 46 TableType string `json:"table_type"` 47 DataType string `json:"data_type"` 48 DataLocation string `json:"data_location"` 49 StorageProperties []map[string]interface{} `json:"storage_properties"` 50 TableComment string `json:"table_comment"` 51 CreateTableSql string `json:"create_table_sql"` 52 } 53 54 type Column struct { 55 ColumnName string `json:"column_name"` 56 Type string `json:"type"` 57 Description string `json:"description"` 58 IsPartitionColumn bool `json:"is_partition_column"` 59 } 60 61 type PartitionsResp struct { 62 IsSuccess bool `json:"is_success"` 63 Message string `json:"message"` 64 Partitions PartitionsInfo `json:"partitions"` 65 } 66 67 type PartitionsInfo struct { 68 TotalCount int `json:"total_count"` 69 PartitionInfos []Partition `json:"partition_infos"` 70 } 71 72 type Partition struct { 73 PartitionName string `json:"partition_name"` 74 CreateTime int `json:"create_time"` 75 LastAccessTime int `json:"last_access_time"` 76 Locations []string `json:"locations"` 77 LastDdlTime int `json:"last_ddl_time"` 78 NumRows int `json:"num_rows"` 79 NumFiles int `json:"num_files"` 80 TotalSize int `json:"total_size"` 81 }