These are chat archives for getredash/redash

16th
Mar 2016
Lloyd Weehuizen
@lloydw
Mar 16 2016 02:45
@markchatters sql supports selection between two dates you just have to and it - SELECT * FROM MEASURES WHERE MEASUREMENT_DATE >= '2016-01-01' AND MEASUREMENT_DATE <= '2016-02-01'
Lloyd Weehuizen
@lloydw
Mar 16 2016 03:04
@arikfr I'm doing some selection from elasticsearch, I want to graph the number of requests that match a search by day, doesn't look like the visualization can currently handle that? It kinda needs to do the group by client side? I tried an elasticsearch aggregation, but it seems the data source doesn't support that, wondering if adding that functionality to the ES datasource is the quickest solution? Thanks
rohanpd
@rohanpd
Mar 16 2016 03:57
Has anyone had luck getting parameters to work with the iframe URL?
I can get this working:
http://demo.redash.io/queries/146?p_action=create
But when I try this it doesn't work:
http://demo.redash.io/embed/query/146/visualization/187?p_action=create&api_key=49b8f1ecb8af98aaa05a300bbc89a83a61d187b5
markchatters
@markchatters
Mar 16 2016 05:49
@lloydw Sorry - I wasn't clear. I meant selecting a "from" and "to" date range as a filter -maybe a calendar control - rather than getting the user to edit the SQL.
Lloyd Weehuizen
@lloydw
Mar 16 2016 06:28
@markchatters you'd have to do your own frontend for that and pass them in as parameters although @rohanpd says parameters don't seem to be working with embedded unfortunately
Arik Fraimovich
@arikfr
Mar 16 2016 06:39
@lloydw to be honest, I never used the ElasticSearch connector myself so not sure. I'm not sure what it will require to support aggregate queries, but I suspect it might be not that much work, so might be worth it.
@markchatters yes, you can use parameters for this, but currently there is no support for creating a UI. It is planned, and I really hope to get to it in the next month or so...
@rohanpd parameters are not supported on embeds. I recently started adding support for parameters in the backend, so it's quite easy to add into embeds. But it is a security risk with current implementation, as it's open to SQL injections. If you embed in internal applications, than it's less of concern, but something to keep in mind.
rohanpd
@rohanpd
Mar 16 2016 07:27
@arikfr we plan on using it in internal applications so super keen to see this supported. With your recent changes in the back end would it be possible for us to enable this feature via a configuration switch?
Arik Fraimovich
@arikfr
Mar 16 2016 07:28
@rohanpd can you open an issue on GitHub for this?
Lloyd Weehuizen
@lloydw
Mar 16 2016 08:30
@arikfr thanks, looking at the code it should be pretty straight forward, so I will plan to go that way
Arik Fraimovich
@arikfr
Mar 16 2016 08:36
@lloydw looking forward for a pull request ;-)
Arik Fraimovich
@arikfr
Mar 16 2016 08:47
@lloydw thank you for the kind words on Twitter. :-) also really envy you for being from Wanaka. Me and my wife traveled New Zealand a few years back. Really hoping to come back some day.
snirad
@snirad
Mar 16 2016 12:26
Hi Arik, Is there a way to delete an alert ? Since the alert is connected to a query, shouldn't it get automaticly remove once i archive a query ?
Arik Fraimovich
@arikfr
Mar 16 2016 12:29
@snirad good point. it should
@snirad opened an issue: getredash/redash#930
snirad
@snirad
Mar 16 2016 12:31
gr8 thanks :)
Arik Fraimovich
@arikfr
Mar 16 2016 12:33
@snirad btw, I'm across the street at the AWS loft, if you want to hash out a few questions in person :)
snirad
@snirad
Mar 16 2016 13:10
coming!
Arik Fraimovich
@arikfr
Mar 16 2016 13:17
@snirad I'm axtua
@snirad I'm actually leaving in a few minutes
snirad
@snirad
Mar 16 2016 13:20
ouh well i just got back ;)
Inkitt
@inkitt
Mar 16 2016 19:02
hey guys! is the kibana integration working?
it doesn't work for me :(
also elastic search doesn't work. it says "Executing query… <TIME>"
but I'm waiting already since 5 minutes.
kibana shows the results from elastic search within few seconds. so it cannot be that slow.
there must be a bug I guess?
Arik Fraimovich
@arikfr
Mar 16 2016 19:34
@AliAlbazaz might be a connectivity issue and it waits for a timeout. Did you allow access to your ES cluster from the Redash machine?
Inkitt
@inkitt
Mar 16 2016 19:45
Yes, it should be able to access it
I removed even all auth
to test
Arik Fraimovich
@arikfr
Mar 16 2016 19:46
did you try querying it with curl directly from the server?
eschultze
@eschultze
Mar 16 2016 19:59
hello all! has someone ever done a dropdown list from mysql query?
Inkitt
@inkitt
Mar 16 2016 20:03
@arikfr yes it works with curl
Arik Fraimovich
@arikfr
Mar 16 2016 20:09
I see. can you try and run another query and see if it keeps executing for ever?
Inkitt
@inkitt
Mar 16 2016 20:19
yes, takes still forever...
Arik Fraimovich
@arikfr
Mar 16 2016 20:19
does it say "query in queue..." or "executing query" ?
Inkitt
@inkitt
Mar 16 2016 20:20
Executing query
Arik Fraimovich
@arikfr
Mar 16 2016 20:20
what is the query you're running?
Inkitt
@inkitt
Mar 16 2016 20:21
aaaah works now!!!
had forgotten the port :(
embarrassing
Arik Fraimovich
@arikfr
Mar 16 2016 20:21
:) glad it's working
Inkitt
@inkitt
Mar 16 2016 20:22
another quick question: is it somehow possible to calculate values based on 2 different databases? e.g. devide a value from elastic search by a value from postgres?
Lloyd Weehuizen
@lloydw
Mar 16 2016 20:33
@arikfr no worries, yeah its a great place to be :) Sometimes can be a bit far away though
@AliAlbazaz you can use the Python data source to combined results from other queries
@AliAlbazaz UI support is planned, but not available yet
Inkitt
@inkitt
Mar 16 2016 20:36
what do you mean with python data source?
you mean I should write my own data source for redash?
@arikfr the weird things is now that I get a result from elastic search but it's empty :(
Lloyd Weehuizen
@lloydw
Mar 16 2016 20:43
@AliAlbazaz no you can write python code directly into a query - redash's best kept secret!
See the example
Inkitt
@inkitt
Mar 16 2016 21:01
that looks cool :)
@arikfr found the "bug" I think. the elastic search adapter can only show the "hits" in the JSON that is returned from elastic search. but it cannot show the "aggregations" inside the JSON
Lloyd Weehuizen
@lloydw
Mar 16 2016 21:35
@AliAlbazaz haha yes
just what I ran into yesterday
I'm planning to add that feature, but feel free to beat me to it :)