month() function returns a dual, so a text representation ('Jan',Feb',...) as well as a numerical representation (1,2,3...). You can force QV to return one or the other by using text() resp. num() function.
Could you describe you problem a bit closer, e.g by by posting a snippet of your load script?
The Datename Sql function returns full month name but then sorting gives problem. The month qlikview function expected to return Jan,Feb but writes month number.
Bottom line: If you call month() function in a SQL SELECT, you call the SQL function (as with datename), no QV functions are known within the SQL SELECT part of your script. You can use QV month() or any other QV functions only outside the SQL SELECT, e.g. in a preceding LOAD or a resident LOAD.
month(OrderDate) as OrdMnth; // calling the QV month function
SQL SELECT CustomerID,
Datename(month,OrderDate) As OrdMnthNm, // calling SQL function
year(OrderDate) AS OrdYear // calling SQL function