I once saw a video on the internet, showing two human beings, a man and a woman, finding a sea creature stranded on a beach.  As I remember they picked it up and carried it to the water.

It was a whale.

Specifically it was a dwarf sperm whale (Kogia sima) or a pigmy sperm whale (Kogia breviceps).  Since their normal adult weights are 136 to 272 kilograms (300 to 600 pounds) and 400 kilograms (860 pounds) respectively, it should have been a juvenile not yet full grown.

The smallest species of cetacean living today is the Vaquita (Phocoena sinus) of the Gulf of California, which is much sorter than dwarf or pigmy sperm whales and weigh up to 120 pounds. 

Vaquitas are classed as porposies, but porposes and dolphins are merely small members of the toothed whales.  They can be considered to be whales as much as the largest whales are.

I am sure that even newly born whales of those species weigh more than any flying animals on Earth today.  However, it is possible that the largest extinct flying birds weighed as much or more than members of the smallest whales species ever, if dolphins and porposes are counted as whales.  

*Quetzalcoatlus*, one of the largest of the extinct flying reptiles, is now usually estimated to have weighed about 220 to 250 kilograms or about 440 to 550 pounds.  That is well within the weight range of adult dwarf sperm whales and close to that of pigmy sperm whales.

Since on a planet with a significantly lower surface gravity and a significantly denser atmospher than Earth, the largest flying creatures could be several times as massive as the largest flying reptiles on Earth, It seems safe to say that even heavier-than-air flying creatures could weigh more than the lightest whales on Earth.  Of course they would look more like the "terror dactyls" seen in dinosaur movies than like whales.

I discuss designing such a planet,  and the limitations in how far one can go while remaining plausible, in my answer at:

https://worldbuilding.stackexchange.com/questions/191008/would-a-small-low-gravity-moon-be-able-to-harbor-complex-life/191115#191115

And of course, on a planet with a much denser atmosphere than Earth, the largest hypothetical floating balloon-like creatures might be as massive as great whales or even more so.  Although they would look more like dirigibles or hot air balloons than like whales.