OQL runs on the local database but gives an error after deploying to the free public cloud

0
Hi I have several OQL queries working fine in my local development environment. Now I deployed the app to the free public cloud and all OQL-used in microflows do not run anymore because of on error .   1) is debugging in studio pro working the same on the public cloud as on the local environment. Or any idea how to see what the error test is on PostgreSQL. 2) If PostgreSQL needs another syntax, how can this be tested on the local database and on PostgreSQL. Strange that no standard ANSI SQL (in OQL) is used to be platform (database) independent   Any suggestions how to rewrite the 'local' query to make it run on 'PostgreSQL', here is one local working example. Or can this be fixed in another way?   ' SELECT a.ArtikelCode ArtikelCode, k.Jaarweeknr JaarWeekNr, v.Actie Actie, CASE WHEN SUM(v.Hoeveelheid) < 0 THEN        SUM(v.Hoeveelheid) * -1 ELSE    SUM(v.Hoeveelheid)   END Hoeveelheid FROM DMHVoorraadModule.Artikel a, DMHVoorraadModule.kalender k LEFT OUTER JOIN a/DMHVoorraadModule.VoorraadMutatie_Artikel/DMHVoorraadModule.VoorraadMutatie v ON CAST(DATEPART(YEAR, v.Datum) as integer) = k.Jaarnr AND CAST(DATEPART(WEEK, v.Datum) as integer) = k.Weeknr AND CAST(DATEPART(DAY, v.Datum) as integer) = k.Dagnr WHERE  k.Datum >= $BeginDatum AND k.Datum <= $EindDatum AND a.ArtikelCode = $ArtikelCode GROUP BY a.ArtikelCode, k.Jaarweeknr, v.Actie ORDER BY a.ArtikelCode, k.Jaarweeknr, v.Actie '  
asked
1 answers
0

Peter, you might run the local version against a local Postgresql database, to see if the query runs fine on a Postresql database.

 

That might make it easier to debug too.

answered