Skip to content

Commit ad676cc

Browse files
lillo42hazzikbahusoid
committed
Fix SELECT N+1 for not-found=ignore
Fixes #1059 Co-authored-by: Alexander Zaytsev <[email protected]> Co-authored-by: Roman Artiukhin <[email protected]>
1 parent 0b27dd5 commit ad676cc

File tree

16 files changed

+828
-180
lines changed

16 files changed

+828
-180
lines changed

src/NHibernate.Test/Async/NHSpecificTest/NH1001/Fixture.cs

Lines changed: 348 additions & 31 deletions
Large diffs are not rendered by default.
Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
namespace NHibernate.Test.NHSpecificTest.NH1001
2+
{
3+
public class Address
4+
{
5+
public virtual int Id { get; set; }
6+
public virtual string Line { get; set; }
7+
}
8+
}
Lines changed: 6 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -1,25 +1,9 @@
1-
using System;
2-
using System.Collections.Generic;
3-
using System.Text;
4-
51
namespace NHibernate.Test.NHSpecificTest.NH1001
62
{
7-
public class Department
8-
{
9-
private int id;
10-
11-
public int Id
12-
{
13-
get { return id; }
14-
set { id = value; }
15-
}
16-
17-
private string name;
18-
19-
public string Name
20-
{
21-
get { return name; }
22-
set { name = value; }
23-
}
24-
}
3+
public class Department
4+
{
5+
public virtual int Id { get; set; }
6+
public virtual string Name { get; set; }
7+
public virtual int PropRefId { get; set; }
8+
}
259
}
Lines changed: 13 additions & 36 deletions
Original file line numberDiff line numberDiff line change
@@ -1,41 +1,18 @@
1-
using System;
21
using System.Collections.Generic;
3-
using System.Text;
42

53
namespace NHibernate.Test.NHSpecificTest.NH1001
64
{
7-
public class Employee
8-
{
9-
private int id;
10-
11-
public int Id
12-
{
13-
get { return id; }
14-
set { id = value; }
15-
}
16-
17-
private string firstName;
18-
19-
public string FirstName
20-
{
21-
get { return firstName; }
22-
set { firstName = value; }
23-
}
24-
25-
private string lastName;
26-
27-
public string LastName
28-
{
29-
get { return lastName; }
30-
set { lastName = value; }
31-
}
32-
33-
private Department department;
34-
35-
public Department Department
36-
{
37-
get { return department; }
38-
set { department = value; }
39-
}
40-
}
5+
public class Employee
6+
{
7+
public virtual int Id { get; set; }
8+
public virtual string FirstName { get; set; }
9+
public virtual string LastName { get; set; }
10+
public virtual Department Department1 { get; set; }
11+
public virtual Department Department2 { get; set; }
12+
public virtual Department Department3 { get; set; }
13+
public virtual Department Department4 { get; set; }
14+
public virtual Department Department5 { get; set; }
15+
public virtual Address Address { get; set; }
16+
public virtual IList<Phone> Phones { get; set; } = new List<Phone>();
17+
}
4118
}

0 commit comments

Comments
 (0)