Home | Forums | Contact | Search | Syndication  
 
 [login] [create account]   Sunday, July 6, 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: Nested or/and in nHibernate - 7.5.1
Ted Szklenski
Posts: 6
 
Nested or/and in nHibernate - 7.5.1Your last visit to this thread was on 1/1/1970 12:00:00 AM
Posted: 11 May 09 2:17 PM
I am creating a DLL to return to a datagrid and I am trying to get a list of all tickets opened as well os those completed in the last 90 days. My nesting is not working and it is returning no rows. Below is the code:

Sage.Platform.RepositoryHelper rep = Sage.Platform.EntityFactory.GetRepositoryHelper();
Sage.Platform.Repository.ICriteria criteria = rep.CreateCriteria();
Sage.Platform.Repository.IQueryable qry = (Sage.Platform.Repository.IQueryable)rep.Repository;
Sage.Platform.Repository.IExpressionFactory ef = qry.GetExpressionFactory();
criteria.Add(rep.EF.Eq("Contact", contact));
criteria.Add(rep.EF.Ne("StatusCode", "Closed"));
criteria.Add(ef.Disjunction().Add(rep.EF.Eq("StatusCode", "Closed")));
criteria.Add(ef.Conjunction().Add(rep.EF.Gt("CompletedDate", DateTime.Today.AddDays(-90))));
criteria.Add(ef.Conjunction().Add(rep.EF.Eq("Contact", contact)));
criteria.CreateCriteria("AssignedTo", "AssignedTo", JoinType.InnerJoin);
criteria.SetProjection(rep.PF.ProjectionList()
.Add(rep.PF.Property("TicketNumber"))
.Add(rep.PF.Property("StatusCode"))
.Add(rep.PF.Property("CreateDate"))

etc..................
[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): 7/6/2025 1:46:46 PM