mirror of
				https://github.com/nsnail/FreeSql.git
				synced 2025-11-04 09:15:27 +08:00 
			
		
		
		
	- 修复 ZeroDbContext GroupBy BUG;
This commit is contained in:
		@@ -766,7 +766,8 @@ namespace FreeSql.Extensions.ZeroEntity
 | 
				
			|||||||
				if (string.IsNullOrWhiteSpace(sql)) return this;
 | 
									if (string.IsNullOrWhiteSpace(sql)) return this;
 | 
				
			||||||
				_useStates = false;
 | 
									_useStates = false;
 | 
				
			||||||
				_groupBy = $"{_groupBy}, {sql}";
 | 
									_groupBy = $"{_groupBy}, {sql}";
 | 
				
			||||||
				_select.GroupBy(_groupBy);
 | 
									_useStates = false;
 | 
				
			||||||
 | 
									_select.GroupBy(_groupBy.Substring(2));
 | 
				
			||||||
				return this;
 | 
									return this;
 | 
				
			||||||
			}
 | 
								}
 | 
				
			||||||
			public SelectImpl GroupBy(string[] fields)
 | 
								public SelectImpl GroupBy(string[] fields)
 | 
				
			||||||
@@ -783,7 +784,7 @@ namespace FreeSql.Extensions.ZeroEntity
 | 
				
			|||||||
				if (count > 0)
 | 
									if (count > 0)
 | 
				
			||||||
				{
 | 
									{
 | 
				
			||||||
					_useStates = false;
 | 
										_useStates = false;
 | 
				
			||||||
					_select.GroupBy(_groupBy);
 | 
										_select.GroupBy(_groupBy.Substring(2));
 | 
				
			||||||
				}
 | 
									}
 | 
				
			||||||
				return this;
 | 
									return this;
 | 
				
			||||||
			}
 | 
								}
 | 
				
			||||||
 
 | 
				
			|||||||
		Reference in New Issue
	
	Block a user