pg_statistic_ext_data.h 2.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960
  1. /*-------------------------------------------------------------------------
  2. *
  3. * pg_statistic_ext_data.h
  4. * definition of the "extended statistics data" system catalog
  5. * (pg_statistic_ext_data)
  6. *
  7. * This catalog stores the statistical data for extended statistics objects.
  8. *
  9. * Portions Copyright (c) 1996-2022, PostgreSQL Global Development Group
  10. * Portions Copyright (c) 1994, Regents of the University of California
  11. *
  12. * src/include/catalog/pg_statistic_ext_data.h
  13. *
  14. * NOTES
  15. * The Catalog.pm module reads this file and derives schema
  16. * information.
  17. *
  18. *-------------------------------------------------------------------------
  19. */
  20. #ifndef PG_STATISTIC_EXT_DATA_H
  21. #define PG_STATISTIC_EXT_DATA_H
  22. #include "catalog/genbki.h"
  23. #include "catalog/pg_statistic_ext_data_d.h"
  24. /* ----------------
  25. * pg_statistic_ext_data definition. cpp turns this into
  26. * typedef struct FormData_pg_statistic_ext_data
  27. * ----------------
  28. */
  29. CATALOG(pg_statistic_ext_data,3429,StatisticExtDataRelationId)
  30. {
  31. Oid stxoid BKI_LOOKUP(pg_statistic_ext); /* statistics object
  32. * this data is for */
  33. bool stxdinherit; /* true if inheritance children are included */
  34. #ifdef CATALOG_VARLEN /* variable-length fields start here */
  35. pg_ndistinct stxdndistinct; /* ndistinct coefficients (serialized) */
  36. pg_dependencies stxddependencies; /* dependencies (serialized) */
  37. pg_mcv_list stxdmcv; /* MCV (serialized) */
  38. pg_statistic stxdexpr[1]; /* stats for expressions */
  39. #endif
  40. } FormData_pg_statistic_ext_data;
  41. /* ----------------
  42. * Form_pg_statistic_ext_data corresponds to a pointer to a tuple with
  43. * the format of pg_statistic_ext_data relation.
  44. * ----------------
  45. */
  46. typedef FormData_pg_statistic_ext_data *Form_pg_statistic_ext_data;
  47. DECLARE_TOAST(pg_statistic_ext_data, 3430, 3431);
  48. DECLARE_UNIQUE_INDEX_PKEY(pg_statistic_ext_data_stxoid_inh_index, 3433, StatisticExtDataStxoidInhIndexId, on pg_statistic_ext_data using btree(stxoid oid_ops, stxdinherit bool_ops));
  49. #endif /* PG_STATISTIC_EXT_DATA_H */