Quantcast
Viewing all articles
Browse latest Browse all 23857

How to get Percentage of 2 coulmns in SQL

Hi,

I have a table which looks like

Name         Apple          Oranges

Abc             10                100

XYZ             300               120

I want to calculate percentage so it should show me as

Name                 Apple                    Oranges

abc                       9                        91

XYZ                     71                        29

Any suggestions pls

Regards

               


Viewing all articles
Browse latest Browse all 23857

Trending Articles