The White Flute and Black Flutes raise and lower the encounter rate, respectively. They last as long as you're in the general area you used it if (if you used it on Route 115, and then moved one tile over to Route 114, the effect would disappear).
And the White Flute does have an advantage over Sweet Scent in certain areas... Sweet Scent is good where there's a really, really, low encounter rate (like underwater) but in places where there's already a pretty decent encounter rate, it's probably easier to use the White Flute and walk aimlessly back and forth than the open the menu each time to use Sweet Scent.