Home | Forums | Contact | Search | Syndication  
 
 [login] [create account]   Monday, August 18, 2025 
 
slxdeveloper.com Community Forums  
   
The Forums on slxdeveloper.com are now retired. The forum archive will remain available for the time being. Thank you for your participation on slxdeveloper.com!
 Web Forums - SalesLogix Web Platform & Application Architect
Forum to discuss the use of the SalesLogix Web Platform, Client and Customer Portals, and the Application Architect (For version 7.2 and higher only). View the code of conduct for posting guidelines.
Forums RSS Feed


 Back to Forum List | Back to SalesLogix Web Platform & Application Architect | New ThreadView:  Search:  
 Author  Thread: Insert Opportunity Product question
Steve Knowles
Posts: 657
Top 10 forum poster: 657 posts
 
Insert Opportunity Product questionYour last visit to this thread was on 1/1/1970 12:00:00 AM
Posted: 23 Apr 09 7:52 AM
On the insert opp product screen there are several filters at the top of the screen (Name,Family, SKU). I think I have an upgraded 7.2 version of the form with Description as a choice oob. The Description filter seems to have disappeared from the screen in 7.5 - presumably to 'fix' a bug. I get an error when trying to use this filter - it displays a long sql statment and at the end an error message. Here is a shorten version of the error:

could not execute query [ SELECT ... FROM PRODUCT this_ WHERE lower(this_.DESCRIPTION) like ? ORDER BY this_.NAME asc]:
Argument data type text is invalid for argument 1 of lower function.


So description is a text field where the others are vchar. Apparently this code called by the filters will not handle making Description lowercase.

Specifically - Is it possible to get at this code and remove the lower() function from this line? lower(this_.DESCRIPTION) Generally - where is this code that is returning the error located? I am guessing somewhere deep in the belly of nhibernate.

Here is the code that returns the error when using the description filter from the insert opp screen:
public object GetProductList()
{
IRepository productRep = EntityFactory.GetRepository();
IQueryable qryableProduct = (IQueryable)productRep;
IExpressionFactory expProduct = qryableProduct.GetExpressionFactory();
Sage.Platform.Repository.ICriteria criteriaProduct = qryableProduct.CreateCriteria();

if (_State.NameFilter != string.Empty)
{
SearchParameter enumCondition = (SearchParameter)_State.NameCond;
criteriaProduct.Add(GetExpression(expProduct, enumCondition, "Name", _State.NameFilter));
}

if (_State.DescFilter != string.Empty)
{
// SearchParameter enumCondition = (SearchParameter)_State.DescCond;
SearchParameter enumCondition = SearchParameter.Contains;
criteriaProduct.Add(GetExpression(expProduct, enumCondition, "Description", _State.DescFilter));
}

if (_State.SKUFilter != string.Empty)
{
SearchParameter enumCondition = (SearchParameter)_State.SKUCond;
criteriaProduct.Add(GetExpression(expProduct, enumCondition, "ActualId", _State.SKUFilter));
}

if (_State.FamilyFilter != string.Empty)
{
SearchParameter enumCondition = SearchParameter.Contains;
criteriaProduct.Add(GetExpression(expProduct, enumCondition, "Family", _State.FamilyFilter));
}

if (_State.StatusFilter != string.Empty)
{
SearchParameter enumCondition = SearchParameter.EqualTo;
criteriaProduct.Add(GetExpression(expProduct, enumCondition, "Status", _State.StatusFilter));
}

if (chkPackage.Checked)
{

}
criteriaProduct.AddOrder(expProduct.Asc("Name"));
List ProductList = criteriaProduct.List() as List;
return ProductList;
}
[Reply][Quote]
 Page 1 of 1 
  You can subscribe to receive a daily forum digest in your user profile. View the site code of conduct for posting guidelines.

   Forum RSS Feed - Subscribe to the forum RSS feed to keep on top of the latest forum activity!
 

 
 slxdeveloper.com is brought to you courtesy of Ryan Farley & Customer FX Corporation.
 This site, and all contents herein, are Copyright © 2025 Customer FX Corporation. The information and opinions expressed here are not endorsed by Sage Software.

code of conduct | Subscribe to the slxdeveloper.com Latest Article RSS feed
   
 
page cache (param): 8/18/2025 2:23:07 AM