Skip to content
Advertisement

Divide each value of a column by the total count of records in a table

A query that is capable of dividing each value of a column by the total number of records in the table

I tried the following query

I see an error and not able to execute the query. for example
total records is 5 so (1/5)*100 = 20

Advertisement

Answer

use analytic count(*) over():

User contributions licensed under: CC BY-SA
9 People found this is helpful
Advertisement