Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

document mapping #272

Open
ulutomaz opened this issue Jul 6, 2017 · 2 comments
Open

document mapping #272

ulutomaz opened this issue Jul 6, 2017 · 2 comments

Comments

@ulutomaz
Copy link

ulutomaz commented Jul 6, 2017

Can I, at document creation, define that some specific document field, with name "ts" is of type date, with specific format?

Like with PUT call and body content

{
"properties": {
"ts": {"type": "date", "format": "epoch_millis"}
}
}

Can this be done with Tirexs?

Really appreciate your help.

@OpakAlex
Copy link
Collaborator

OpakAlex commented Jul 6, 2017

try do just http call. Where is problem?)

@sebastialonso
Copy link

You can do it with the HTTP call (see Tirexs.HTTP.post). I'm passing a keyword list structure like

[index: "data-obj", type: "data-obj",
 mapping: [properties: [job: [type: "keyword"],
   name: [type: "text", analyzer: "nGram_analyzer"],
   released: [type: "date", format: "dd/MM/yyyy"]]]]

here released is my date format with its own specific format.

Hope it helps.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants