1.建立索引
PUT /index_trans_detail

2.建立mapping
POST /index_trans_detail/type_trans_detail/_mapping
{
"type_trans_detail": {
"properties": {
"id": {
"type": "long"
},
"entId": {
"type": "long"
},
"orgId": {
"type": "long"
},
"seqno": {
"type": "text",
"fielddata": true
},
"transDate": {
"type": "date",
"format": "yyyy-MM-dd"
},
"postTatus": {
"type": "integer"
},
"ioFlag": {
"type": "integer"
},
"depotId": {
"type": "long"
},
"depotCode": {
"type": "keyword"
},
"depotName": {
"type": "text"
},
"depotClassId": {
"type": "long"
},
"depotClassCode": {
"type": "keyword"
},
"depotClassName": {
"type": "text"
},
"orgOrgId": {
"type": "long"
},
"orgOrgCode": {
"type": "keyword"
},
"orgOrgName": {
"type": "text"
},
"orgOrgClassId": {
"type": "long"
},
"orgOrgClassCode": {
"type": "keyword"
},
"orgOrgClassName": {
"type": "text"
},
"balOrgId": {
"type": "long"
},
"balOrgCode": {
"type": "keyword"
},
"balOrgName": {
"type": "text"
},
"transOrgId": {
"type": "long"
},
"transOrgCode": {
"type": "keyword"
},
"transOrgName": {
"type": "text"
},
"transOrgClassId": {
"type": "long"
},
"transOrgClassCode": {
"type": "keyword"
},
"transOrgClassName": {
"type": "text"
},
"transBalOrgId": {
"type": "long"
},
"transBalOrgCode": {
"type": "keyword"
},
"transBalOrgName": {
"type": "text"
},
"transTypeId": {
"type": "long"
},
"transType": {
"type": "keyword"
},
"transName": {
"type": "text"
},
"dutyBillId": {
"type": "long"
},
"dutyBillType": {
"type": "integer"
},
"dutyBillNo": {
"type": "text",
"fielddata": true
},
"sourceId": {
"type": "long"
},
"sourceType": {
"type": "integer"
},
"sourceNo": {
"type": "keyword"
},
"billStatus": {
"type": "integer"
},
"headRemark": {
"type": "text"
},
"isAllowDel": {
"type": "integer"
},
"useOrgId": {
"type": "long"
},
"headIoQty": {
"type": "double"
},
"headIoAmt": {
"type": "double"
},
"headIoCostAmt": {
"type": "double"
},
"periodNo": {
"type": "text"
},
"externalBillNo": {
"type": "text"
},
"externalSysType": {
"type": "integer"
},
"useDepId": {
"type": "long"
},
"useDepCode": {
"type": "keyword"
},
"useDepName": {
"type": "text"
},
"usePurpose": {
"type": "integer"
},
"transId": {
"type": "long"
},
"goodsId": {
"type": "long"
},
"goodsCode": {
"type": "keyword"
},
"goodsName": {
"type": "text"
},
"goodsClassId": {
"type": "long"
},
"goodsClassCode": {
"type": "keyword"
},
"goodsClassName": {
"type": "text"
},
"goodsSpec": {
"type": "keyword"
},
"goodsOrigin": {
"type": "text"
},
"postFlag": {
"type": "integer"
},
"goodsWeight": {
"type": "double"
},
"ioQty": {
"type": "double"
},
"ioPrice": {
"type": "double"
},
"ioAmt": {
"type": "double"
},
"unitId": {
"type": "long"
},
"unitName": {
"type": "text"
},
"unitRate": {
"type": "double"
},
"iocostPrice": {
"type": "double"
},
"ioCostAmt": {
"type": "long"
},
"feeAmt": {
"type": "long"
},
"lotId": {
"type": "long"
},
"dutyBillDetailId": {
"type": "long"
},
"sourceDetailId": {
"type": "long"
},
"dutyOrgId": {
"type": "long"
},
"postUserId": {
"type": "long"
},
"postDateTime": {
"type": "date",
"format": "yyyy-MM-dd HH:mm:ss"
},
"postReturnId": {
"type": "long"
},
"errMsg": {
"type": "text"
},
"firstPostDatetime": {
"type": "date",
"format": "yyyy-MM-dd HH:mm:ss"
},
"balanceFlag": {
"type": "integer"
},
"remark": {
"type": "text"
},
"baseQty": {
"type": "double"
},
"baseUnitId": {
"type": "long"
},
"baseUnitName": {
"type": "text"
},
"baseUnitPrice": {
"type": "double"
},
"createType": {
"type": "integer"
},
"createHeadId": {
"type": "long"
},
"invUnitId": {
"type": "long"
},
"invUnitCode": {
"type": "keyword"
},
"invUnitName": {
"type": "text"
},
"invUnitRate": {
"type": "double"
},
"invQty": {
"type": "double"
},
"invCostPrice": {
"type": "double"
},
"discountRate": {
"type": "double"
},
"discountTaxRate": {
"type": "double"
},
"taxRate": {
"type": "double"
},
"taxAmt": {
"type": "double"
},
"ioBillStatus": {
"type": "integer"
},
"ioBillTime": {
"type": "date",
"format": "yyyy-MM-dd HH:mm:ss"
},
"ioBillQty": {
"type": "double"
},
"taxType": {
"type": "integer"
},
"isStoBackPrice": {
"type": "integer"
},
"stoCostPrice": {
"type": "double"
},
"stoCostAmt": {
"type": "double"
},
"version": {
"type": "integer"
},
"deleted": {
"type": "long"
},
"creatorCode": {
"type": "keyword"
},
"creatorName": {
"type": "text",
"fielddata": true
},
"createdAt": {
"type": "date",
"format": "yyyy-MM-dd HH:mm:ss"
},
"creatorOrgCode": {
"type": "keyword",
"index": false
},
"modifierCode": {
"type": "keyword",
"index": false
},
"modifierName": {
"type": "text"
},
"lastModifiedAt": {
"type": "date",
"format": "yyyy-MM-dd HH:mm:ss"
},
"modifierOrgCode": {
"type": "keyword",
"index": false
},
"invTransHeadId": {
"type": "long"
},
"handledOrgCode": {
"type": "keyword"
},
"handledOrgName": {
"type": "text"
},
"createdAtTimestamp": {
"type": "date",
"format": "epoch_millis"
},
"transDateTimestamp": {
"type": "date",
"format": "epoch_millis"
},
"lastModifiedTimestamp": {
"type": "date",
"format": "epoch_millis"
},
"postDateTimeTimestamp": {
"type": "date",
"format": "epoch_millis"
},
"ioBillTimeTimestamp": {
"type": "date",
"format": "epoch_millis"
},
"firstPostDatetimeTimestamp": {
"type": "date",
"format": "epoch_millis"
}
}
}
}

3.建立别名
PUT /index_trans_detail/_alias/index_trans_detail_alias

转载于:https://www.cnblogs.com/zeenzhou/p/11588631.html

ES建立索引步骤, 1,index 2.mapping 3,别名相关推荐

  1. 用oracle建立索引步骤,Oracle建立全文索引的步骤

    Oracle全文索引相信大家都有一定的了解,下面就教您如何建立oracle全文索引,如果您对oracle全文索引方面感兴趣的话,不妨一看. 步骤一 检查和设置数据库角色 首先检查数据库中是否有CTXS ...

  2. 数据库建立索引、数据表创建规则、备用字段 / 保留字段 / 预留字段

    数据库建立索引 数据库.数据表建立索引的原则 数据库建立索引的原则 1,确定针对该表的操作是大量的查询操作还是大量的增删改操作. 2,尝试建立索引来帮助特定的查询.检查自己的sql语句,为那些频繁在w ...

  3. MySQL:给表建立索引及索引的显示

    建表: create table user(     id int not null primary key,     username varchar(15) not null,     passw ...

  4. mysql对yggl数据的建立索引_employees数据库

    alter table Salary add constraint PK_S foreign key(EmployeeID) references Employees(EmployeeID) on d ...

  5. 创建索引oracle 很慢,Oracle 建立索引及SQL优化

    复合索引用户可以在多个列上建立索引,这种索引叫做复合索引(组合索引).复合索引的创建方法与创建单一索引的方法完全一样.但复合索引在数据库操作期间所需的开销更小,可以代替多个单一索引. 如何某表的某个字 ...

  6. 包你学会怎么在oracle中建立索引

    查询某张表中哪些字段创建了索引: select user_ind_columns.index_name,user_ind_columns.column_name, user_ind_columns.c ...

  7. 【ES笔记01】ElasticSearch数据库之index索引、doc文档、alias别名、mappings映射结构的基本操作

    这篇文章,主要介绍ElasticSearch数据库之index索引.doc文档.alias别名.mappings映射结构的基本操作. 目录 一.索引index相关操作 1.1.创建索引 1.2.查询索 ...

  8. mysql建立索引的优缺点|创建索引alter或create索引分类(PRIMARY KEY,UNIQUE KEY,FULLTEXT,INDEX)作用查看索引show index from table

    建立索引的优缺点: 为什么要创建索引呢? 这是因为,创建索引可以大大提高系统的性能.          第一.通过创建唯一性索引,可以保证数据库表中每一行数据的唯一性.          第二.可以大 ...

  9. mongodb 建立索引提示异常:WiredTigerIndex::insert: key too large to index, failing 1483

    mongodb 建立索引提示异常:WiredTigerIndex::insert: key too large to index, failing 1483 参考文章: (1)mongodb 建立索引 ...

最新文章

  1. linux c 调试 strace 诊断 调试程序 异常退出 崩溃
  2. (私人收藏)2019科协WER解决方案
  3. osmnx 笔记: plot_graph_route plot_graph_routes
  4. golang安装grpc,timeout问题
  5. Ionic JPush极光推送 插件实例
  6. numpy.argmax/argmin/max/min
  7. Oracle的体系结构
  8. linux内核编译,内核参数修改
  9. Ansible 详细用法部署安装
  10. 奇安信代码卫士报送的漏洞获评“CNVD平台2019年度最具价值漏洞”
  11. 【HNOI2003】【BZOJ1218】激光炸弹
  12. python 学习day3
  13. 通过银行卡的Bin号来获取银行名称
  14. F2FS的sysfs调整文件系统参数
  15. 语音识别开源项目汇总
  16. 大学生怎样学习一门编程
  17. android 指南针不稳定,Android指南针方向不可靠(低通滤波器)
  18. 光端机连接示意图详细连接方式图解
  19. python中的序列类型数据结构元素的切片操作_PythonI/O进阶学习笔记_4.自定义序列类(序列基类继承关系/可切片对象/推导式)...
  20. Clustering coefficient的计算

热门文章

  1. SVN命令行更新代码
  2. Virtual Network (1) - How to use it in a guest
  3. [Linux]变量加减赋值以及将String转int
  4. 详解模板方法设计模式
  5. 802d简明调试手册_SINUMERIK-828D简明调试手册.pdf
  6. ajax预加载html seo,前端性能优化 — JS预加载和懒加载
  7. find 命令示例_数组find()方法以及JavaScript中的示例
  8. html流动海报css,海报网css代码怎样把模块移到右面?最好把代码直接给我!嘿嘿。...
  9. from rfc 2068 hypertext怎么解决_你好,打工人!用英语怎么表达“打工人”?可别直接说 worker...
  10. php商品在最少购买,ECSHOP给商品设置最少购买数量的方法