min and max functions in reports

Discussion of open issues, suggestions and bugs regarding database management and administration tools for MySQL
Post Reply
fattbass
Posts: 4
Joined: Thu 14 Mar 2013 19:07

min and max functions in reports

Post by fattbass » Thu 14 Mar 2013 19:34

Hello everybody !

i want to do simple things in report, but ...
i have db, table, rows, columns, data etc , for example let`s take column_A and column_B
i want to have 3 fields,
x = max(column_A) and y = min(column_B) and z = x - y

in short i want subtract result ( ( max(column_A) - min(column_B) ) and put in another field (number 3). I hope you all understand my wishes :)

As far i known with calculated fields it cannot be done, because of syntax ? Because can`t subtract calculatedfield1-calculatedfield2 , and calculatedfield even can not show max and min values

Best Regards.

Thanks in advance.

alexa

Re: min and max functions in reports

Post by alexa » Fri 15 Mar 2013 12:48

This can be achieved as follows:

1. Select 'File -> New -> Data Report' from the main menu. The 'Data Report Wizard' window opens.
2. Click 'Next'.
3. Select the 'Custom Query' radio button.
4. Click 'Next'.
5. Insert the query below and complete the wizard:

SELECT MAX(column_A) as x, MIN(column_B) AS y, ( max(column_A) - min(column_B)) AS z FROM table

fattbass
Posts: 4
Joined: Thu 14 Mar 2013 19:07

Re: min and max functions in reports

Post by fattbass » Fri 15 Mar 2013 15:22

alexa wrote:This can be achieved as follows:

1. Select 'File -> New -> Data Report' from the main menu. The 'Data Report Wizard' window opens.
2. Click 'Next'.
3. Select the 'Custom Query' radio button.
4. Click 'Next'.
5. Insert the query below and complete the wizard:

SELECT MAX(column_A) as x, MIN(column_B) AS y, ( max(column_A) - min(column_B)) AS z FROM table
thank you, it is working 8)

is it possible to export report using command line ? for example, i make report and in command line i export that report, like from user GUI. I can not find anything about reports in command line in documentation.

alexa

Re: min and max functions in reports

Post by alexa » Mon 18 Mar 2013 09:50

This can be performed with the beta version of dbForge Studio for MySQL: http://www.devart.com/dbforge/mysql/stu ... nload.html

Here is an example of the command line string:

dbforgemysql.com /datareport /reportfile:"D:\Report1.rdb" /format:PDF /result folder:"d:\"

You can find more examples by typing the following string in the command line prompt:

dbforgemysql.com /datareport /?

fattbass
Posts: 4
Joined: Thu 14 Mar 2013 19:07

Re: min and max functions in reports

Post by fattbass » Mon 18 Mar 2013 13:51

alexa wrote:This can be performed with the beta version of dbForge Studio for MySQL: http://www.devart.com/dbforge/mysql/stu ... nload.html

Here is an example of the command line string:

dbforgemysql.com /datareport /reportfile:"D:\Report1.rdb" /format:PDF /result folder:"d:\"

You can find more examples by typing the following string in the command line prompt:

dbforgemysql.com /datareport /?
big thank you ! you`re my GOD ! :D

as far as i understand exporting reports with command line is only possible in BETA, and in 5.0 version it can not be done ?

alexa

Re: min and max functions in reports

Post by alexa » Mon 18 Mar 2013 15:05

You are right. Such functionality is present only in the new beta version 6.0.

fattbass
Posts: 4
Joined: Thu 14 Mar 2013 19:07

Re: min and max functions in reports

Post by fattbass » Mon 18 Mar 2013 15:09

alexa wrote:You are right. Such functionality is present only in the new beta version 6.0.
thank you, no more questions 8)

Post Reply