统计新增索引.txt 3.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116
  1. 创建索引
  2. POST http://172.19.103.68:9200/hlw_quota_test
  3. 查询索引
  4. GET http://172.19.103.68:9200/hlw_quota_test/
  5. 给索引加mapping
  6. POST http://172.19.103.68:9200/hlw_quota_test/hlw_quota_test/_mapping
  7. {
  8. "hlw_quota_test": {
  9. "properties": {
  10. "quotaCode": {
  11. "type": "string",
  12. "index": "not_analyzed"
  13. },
  14. "city": {
  15. "type": "string",
  16. "index": "not_analyzed"
  17. },
  18. "cityName": {
  19. "type": "string",
  20. "index": "not_analyzed"
  21. },
  22. "town": {
  23. "type": "string",
  24. "index": "not_analyzed"
  25. },
  26. "townName": {
  27. "type": "string",
  28. "index": "not_analyzed"
  29. },
  30. "hospital": {
  31. "type": "string",
  32. "index": "not_analyzed"
  33. },
  34. "hospitalName": {
  35. "type": "string",
  36. "index": "not_analyzed"
  37. },
  38. "dept": {
  39. "type": "string",
  40. "index": "not_analyzed"
  41. },
  42. "deptName": {
  43. "type": "string",
  44. "index": "not_analyzed"
  45. },
  46. "doctor": {
  47. "type": "string",
  48. "index": "not_analyzed"
  49. },
  50. "doctorName": {
  51. "type": "string",
  52. "index": "not_analyzed"
  53. },
  54. "slaveKey1": {
  55. "type": "string",
  56. "index": "not_analyzed"
  57. },
  58. "slaveKey1Name": {
  59. "type": "string",
  60. "index": "not_analyzed"
  61. },
  62. "slaveKey2": {
  63. "type": "string",
  64. "index": "not_analyzed"
  65. },
  66. "slaveKey2Name": {
  67. "type": "string",
  68. "index": "not_analyzed"
  69. },
  70. "slaveKey3": {
  71. "type": "string",
  72. "index": "not_analyzed"
  73. },
  74. "slaveKey3Name": {
  75. "type": "string",
  76. "index": "not_analyzed"
  77. },
  78. "slaveKey4": {
  79. "type": "string",
  80. "index": "not_analyzed"
  81. },
  82. "slaveKey4Name": {
  83. "type": "string",
  84. "index": "not_analyzed"
  85. },
  86. "areaLevel": {
  87. "type": "string",
  88. "index": "not_analyzed"
  89. },
  90. "timeLevel": {
  91. "type": "string",
  92. "index": "not_analyzed"
  93. },
  94. "result1": {
  95. "type": "double"
  96. },
  97. "result2": {
  98. "type": "double"
  99. },
  100. "quotaDate": {
  101. "type": "date"
  102. },
  103. "createTime": {
  104. "type": "date"
  105. }
  106. }
  107. }
  108. }
  109. 增加索引搜索大小
  110. PUT http://172.19.103.68:9200/hlw_quota_test/_settings
  111. {
  112. "index": {
  113. "max_result_window": 500000
  114. }
  115. }