1911{
1912 VacAttrStats *stats = (VacAttrStats *)PG_GETARG_POINTER(0);
1913 Form_pg_attribute attr = stats->attr;
1914
1915 POSTGIS_DEBUG(2, "gserialized_analyze_nd called");
1916
1917
1918
1919 if (attr->attstattarget < 0)
1920 attr->attstattarget = default_statistics_target;
1921
1922 POSTGIS_DEBUGF(3, " attribute stat target: %d", attr->attstattarget);
1923
1924
1925
1926
1927 stats->minrows = 300 * stats->attr->attstattarget;
1929
1930 POSTGIS_DEBUGF(3, " minrows: %d", stats->minrows);
1931
1932
1933 PG_RETURN_BOOL(true);
1934}
static void compute_gserialized_stats(VacAttrStats *stats, AnalyzeAttrFetchFunc fetchfunc, int sample_rows, double total_rows)
In order to do useful selectivity calculations in both 2-D and N-D modes, we actually have to generat...