Can any body tell me what is wrong with below query Named SQL Query using NHibernate. As I am getting error - "Error in Named Query : GetSecondReviewIncomeStatements ":
<sql-query name="GetSecondReviewIncomeStatements" read-only="true">
<![CDATA[
SELECT I.TotalNetSales,I.CostOfGoodsSold,I.GrossProfit
FROM IncomeStatement as incomeStatement
INNER JOIN FETCH CompSearchResultItem as resultItem
ON incomeStatement.Comparable.ID = resultItem.Comparable.ID
AND resultItem.CompSearch.ID = :compSearchID
]]>-->
</sql-query>-->
I have searched a lot on the web, some say instead on On
put Where
.
I also tried NamedQuery
only but everytime I get the same error.