HELP!!!! Dividing one field by another on Looker Studio

Please Please Help!

I am no expert but I have tried EVERYTHING suggested and nothing works and I DEFINITELY have the field names correct and they both will work fine in a table.

I want to divide field Total TG_Event by field Hours of Event and I have tried

CASE
WHEN SUM(Hours of Event) = 0 THEN 0
ELSE SUM(Total TG_Event) / SUM(Hours of Event)
END

And lots of variations and I keep getting told - Syntax error: Expected “)” but got “TG_Event”. or similar

Please

Have mercy

Help. I have been trying for ages

@Expert1 @VoiceOfEveryone @support

Hi @Jennifer2

what data source are you connecting to?

From a first glance, I dont see anything wrong with your syntax, but the error you quote indicates that there might be a problem with the space in ‘Total TG_Event’.

Please elaborate a bit more and share screenshots if possible.

Thanks

Hi @Jennifer2 , do you have Looker Studio Pro? If so, you may also want to try out our new Formula Assistant (https://cloud.google.com/blog/products/business-intelligence/ai-powered-slide-generation-and-formula-assistant-in-looker) to see if this helps write the correct formula for you.