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

Unable to place input parameters within query #4

Closed
bertiepinnock opened this issue Feb 5, 2016 · 2 comments
Closed

Unable to place input parameters within query #4

bertiepinnock opened this issue Feb 5, 2016 · 2 comments
Assignees
Labels

Comments

@bertiepinnock
Copy link

Hi,

First off a small disclaimer, I'm not hugely experienced with either Elasticsearch or JasperReports, so apologies if I'm missing something simple.

It doesn't seem to be possible to place parameters (e.g.$P{parameter_name} ) for input controls within the Elasticsearch query, without receiving a Parse Failure exception. I'm fairly certain it's because of the {} special characters confusing things. I've tried escaping the curly brackets with no success.

Is this functionality supported by the plugin? Or am I just missing something?

Otherwise, really great plugin guys!

@Wedjaa
Copy link
Contributor

Wedjaa commented Feb 5, 2016

Hi bertiep,

when using parameters in the query you would use: '$P!{param}', as an example:

{ "query": { "term": { "lastname": "$P!{lastname}" } } }

give it a spin and let me know how it goes.

Fabio

@Wedjaa Wedjaa closed this as completed Feb 5, 2016
@Wedjaa Wedjaa added the question label Feb 5, 2016
@Wedjaa Wedjaa self-assigned this Feb 5, 2016
@bertiepinnock
Copy link
Author

I tried it just now and worked a treat.

I think I had already tried that, but turns out I had a few other mistakes that I'd missed before in there causing problems.

Thanks very much for the help and for getting back to me so quickly!

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

No branches or pull requests

2 participants