ok first off an 18 inch tank isnt suitable for that amount of fish nor is the smaller tank its still over stocked ,this may be part of your problem ill asume your tank is 18x12x12 which is about 10 gallons this really is only suitable for one fish
if is just swimming round and round it could well be stunted ie the internal organs are so bunched up it causes the said syptoms ,you need to thin down the amount of fish you have in the tanks and buy a test kit ,12 fish in an 18 inch tank will produce a massive amount of waste ,the amonia and nitrate levels will be well above normal