DMXzone Server Connect Support Product Page
Answered
custom select queries
Asked 11 Mar 2018 21:25:47
1
has this question
11 Mar 2018 21:25:47 Carlin Chesnet posted:
this type of select would answer my problems but cant customize with current query builder...Sum(IF(year(salesorders.orderdate) = '2017', salesorders.amount, 0.00)) AS `2017`
i have created two serverconnect query actions once that pulls current year sales data and one that pulls 2017 data, i need to show a calculation for my user of there progress to a % higher then 2017 vs 2018 total.
I am outputting the sales data via a group by variable by product lines. the keys are the same in both repeats, but then I don't know how to access the value from the other repeat based on the current key and use a value to do the calculation in the current_year repeat...
Replies
Replied 14 Mar 2018 22:30:22
14 Mar 2018 22:30:22 George Petrov replied:
Hi Carlin,
This is not the best SQL statement to do such computations .. you are having an IF within a SUM. Usually you just do a SUM and filter in the WHERE statement by year ...
Anyway in the current Database Connector this is not possible, but we are working on a new major version 2 that will have totally overhauled visual query builder that supports aggregate functions like SUM
Greetings,
George
This is not the best SQL statement to do such computations .. you are having an IF within a SUM. Usually you just do a SUM and filter in the WHERE statement by year ...
Anyway in the current Database Connector this is not possible, but we are working on a new major version 2 that will have totally overhauled visual query builder that supports aggregate functions like SUM
Greetings,
George
Replied 27 Sep 2019 20:35:04
27 Sep 2019 20:35:04 mike madrid replied:
What is the status of the "new major version 2" that will allow us to do functions such as SUM?
Replied 28 Sep 2019 09:59:29
28 Sep 2019 09:59:29 Teodor Kuduschiev replied:
Hello Mike,
Sum as well as other functions are already available in Database Connector 2:
Sum as well as other functions are already available in Database Connector 2:
Replied 28 Sep 2019 17:26:02
28 Sep 2019 17:26:02 mike madrid replied:
Well.....that sucks!!!! I just bought the original a few months ago!
Replied 30 Sep 2019 14:41:17
30 Sep 2019 14:41:17 mike madrid replied:
@Teodor,
I can never chat with anyone to see if there is a way I can get a substantial discount. This is a functionality I need but don't think DMXZone giving me a discount is out of the question. How can I work this out?
I can never chat with anyone to see if there is a way I can get a substantial discount. This is a functionality I need but don't think DMXZone giving me a discount is out of the question. How can I work this out?