getredash / redash

Make Your Company Data Driven. Connect to any data source, easily visualize, dashboard and share your data.
http://redash.io/
BSD 2-Clause "Simplified" License
26.5k stars 4.39k forks source link

Redash WebApp and Redash API are giving different results for the same query #6743

Open Auburngrads opened 10 months ago

Auburngrads commented 10 months ago

Redash WebApp and Redash API are giving different results for the same query

My orginazation uses Redash as a front-end GUI, for tables created in DataBricks. One of the tables is updated on the first of each month to append the previous month's data. We've been asked to export the data into an Excel file. One option for doing this is to manually export the data from Redash and save it to Excel. My preferred option is to export the data using the Redash API. I'm currently using the R package httr to make calls to the API and export the data. However, I'm having issues where the data returned by the API doesn't include the latest month of data whereas when I use the Redash webapp the table returned does include the newest data.

I thought that this approach, while a bit of an overkill, would avoid getting outdated results - however I was mistaken. At this point I'm at a loss for what to do and I'm not sure how the same query can return different results depending on the method used to submit the query.

Technical details:

guidopetri commented 10 months ago

Hi! Thanks for the bug report. What version of Redash are you using? Do you have an examplo query that is generating different results?

Auburngrads commented 10 months ago

I passed the question about the Redash version on to our admins, but am not sure how quickly they will respond. Where would I find the Redash version information on the web app?

As far as examples, they are all simple queries of the form SELECT * from database.table as most of the work was done upstream in DataBricks to create these output tables.

What's strange is if I go into the web app and run one of the archived queries (that I created using the API) and then use the API again I get the updated table - almost like Redash stores two versions of the table and I need to poke the API to ensure it returns the most current version.

Auburngrads commented 5 months ago

So now it seems that the API is making stuff up.

Finding instances where if I manually run a query on Redash and then use the API run the same query all of the integer valued column are tripled (every value).

The number of rows and columns are the same for both data extracts and the real-valued columns don't appear to be affected.