Skip to content

Commit

Permalink
Merge pull request cockroachdb#42799 from rytaft/backport19.2-42067
Browse files Browse the repository at this point in the history
release-19.2: opt: fix test catalog to not build empty histograms
  • Loading branch information
rytaft authored Nov 26, 2019
2 parents 49c79a1 + fb25db0 commit 0da08d8
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion pkg/sql/opt/testutils/testcat/test_catalog.go
Original file line number Diff line number Diff line change
Expand Up @@ -974,7 +974,7 @@ func (ts *TableStat) NullCount() uint64 {
// Histogram is part of the cat.TableStatistic interface.
func (ts *TableStat) Histogram() []cat.HistogramBucket {
evalCtx := tree.MakeTestingEvalContext(cluster.MakeTestingClusterSettings())
if ts.js.HistogramColumnType == "" {
if ts.js.HistogramColumnType == "" || ts.js.HistogramBuckets == nil {
return nil
}
colType, err := parser.ParseType(ts.js.HistogramColumnType)
Expand Down

0 comments on commit 0da08d8

Please sign in to comment.