新增索引es7.txt 2.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120
  1. es7没有type的概念
  2. 查询索引
  3. get http://172.26.0.56:9200/quota_index
  4. 创建索引
  5. PUT http://172.26.0.56:9200/quota_index
  6. {
  7. "mappings" : {
  8. "properties" : {
  9. "areaLevel" : {
  10. "type" : "integer"
  11. },
  12. "city" : {
  13. "type" : "keyword"
  14. },
  15. "cityName" : {
  16. "type" : "keyword"
  17. },
  18. "createDate" : {
  19. "type" : "date",
  20. "format" : "strict_date_optional_time||epoch_millis"
  21. },
  22. "createTime" : {
  23. "type" : "date",
  24. "format" : "strict_date_optional_time||epoch_millis"
  25. },
  26. "economic" : {
  27. "type" : "keyword"
  28. },
  29. "economicName" : {
  30. "type" : "keyword"
  31. },
  32. "id" : {
  33. "type" : "keyword"
  34. },
  35. "level" : {
  36. "type" : "keyword"
  37. },
  38. "levelName" : {
  39. "type" : "keyword"
  40. },
  41. "org" : {
  42. "type" : "keyword"
  43. },
  44. "orgName" : {
  45. "type" : "keyword"
  46. },
  47. "provice" : {
  48. "type" : "keyword"
  49. },
  50. "provinceName" : {
  51. "type" : "keyword"
  52. },
  53. "quotaCode" : {
  54. "type" : "keyword"
  55. },
  56. "quotaDate" : {
  57. "type" : "date",
  58. "format" : "strict_date_optional_time||epoch_millis"
  59. },
  60. "quotaName" : {
  61. "type" : "keyword"
  62. },
  63. "result" : {
  64. "type" : "double"
  65. },
  66. "saasId" : {
  67. "type" : "keyword"
  68. },
  69. "slaveKey1" : {
  70. "type" : "keyword"
  71. },
  72. "slaveKey1Name" : {
  73. "type" : "keyword"
  74. },
  75. "slaveKey2" : {
  76. "type" : "keyword"
  77. },
  78. "slaveKey2Name" : {
  79. "type" : "keyword"
  80. },
  81. "slaveKey3" : {
  82. "type" : "keyword"
  83. },
  84. "slaveKey3Name" : {
  85. "type" : "keyword"
  86. },
  87. "slaveKey4" : {
  88. "type" : "date",
  89. "format" : "strict_date_optional_time||epoch_millis"
  90. },
  91. "slaveKey4Name" : {
  92. "type" : "date",
  93. "format" : "strict_date_optional_time||epoch_millis"
  94. },
  95. "team" : {
  96. "type" : "keyword"
  97. },
  98. "teamName" : {
  99. "type" : "keyword"
  100. },
  101. "timeLevel" : {
  102. "type" : "integer"
  103. },
  104. "town" : {
  105. "type" : "keyword"
  106. },
  107. "townName" : {
  108. "type" : "keyword"
  109. },
  110. "year" : {
  111. "type" : "keyword"
  112. },
  113. "yearName" : {
  114. "type" : "keyword"
  115. }
  116. }
  117. }
  118. }