In a new post, Vaidy shows us how to Get Month Numbers between two dates in T-SQL
Dynamics GP – Learn & Discuss: Getting Month Numbers between two dates in T-SQL
Archived post from 2011. Dynamics GP and the links it points to have changed since; check current documentation before relying on version-specific steps.