Java and MySQL
I have created a very simple MySQL database and created a table with two columns, namely "X", and "Y".
After that, I created a desktop database Java application for that.
My question is:
I want to add a button that is responsible for calculating the SUM of the "X" column values.
So, in other words, when I press a button, I want get the average of the "X" column as a result.
How can I add this functionality to the button?
So, my issue is just how to apply the SUM command through clicking a button.
Thank you very much for your kind reply.
Do you have any idea how to do that through a tool like NetBeans, especially that some steps will be already automated.
Learn how to do it manually, first. So that you actually know what you're doing and can understand what the IDE does when it does something for you.
Once you know how to do it it yourself, figuring out how to let the IDE do it for you will be almost intuitive, and you will actually understand what's happening so that you will be able to debug it if something goes wrong.
I agree with you.
i dont know how to make GUI by ide... as ide do not know what i want, i may need to check the code again
if i need to check code after those automated tasks, why i just do it manually?
Just in case to make some customizations, like performing some operations (Sum, Average, ...etc).