You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hi good day.
I have the following problem using the following statement alasql
var sql = 'select DISTINCT FROM Period? ORDER BY ASC RequestDate '
var res = alasql (sql, [result]);
With version 0.3 (used in the example), it does not work correctly the DISTINCT, but if the ORDER BY.
With version 0.2.1 (which I use in my project, it works well but not the DISTINCT ORDER BY.
There is a report on DISTINCT malfunction in version 3.
Thank you so much.
NOTE: The sample data are online
<!DOCTYPE html>
<html lang="en">
<script src="https://cdn.jsdelivr.net/alasql/0.3/alasql.min.js"></script>
<script src="https://code.jquery.com/jquery-3.1.1.min.js" type="text/javascript"></script>
<body>
Query result: <div id="result"></div>
</body>
<script>
$.ajax({
type: "POST",
url: "http://databoard.com.ar/COCA/WS_select_SLA_Grafico1.php?var1=&var2=&var3=OLA%20outline%20agreement&var4=&var5=&var6=&var7=&var8=&var9=&var10=",
dataType: 'jsonp',
async: true,
dataF: "{}",
success: function (result) {
var sql = 'select DISTINCT Period FROM ? ORDER BY RequestDate ASC'
var res = alasql(sql , [result]);
document.getElementById("result").innerHTML = JSON.stringify(res);
}
})
</script>
</html>
Activity
cbugari commentedon Sep 26, 2016
Sorry, the correct query is:
var sql = 'select DISTINCT Period FROM ? ORDER BY ASC RequestDate '
var res = alasql (sql, [result]);
mathiasrw commentedon Sep 30, 2016
Hi @cbugari - Sorry long response time.
Thank you so much for a very well described bug.
Its really terrible we have introduced an error - but even worse that our regression tests did not include this scenario.
Small questions - if we have data corresponding to
will you the expect
jul-16orsep-16to come first?This is really