What kind of fish?
It sounds like it could be either constipation or swimbladder disease, If it is eating you could feed with an antibiotic laced food.
There are a couple brands, Jungle makes one that is usually carried by petco and petsmart.
If it is not eating try a drop or two of codliver oil in the fishes mouth, use an eye dropper.