-
Notifications
You must be signed in to change notification settings - Fork 14
/
Copy pathjoin-to-filter.php
33 lines (31 loc) · 1011 Bytes
/
join-to-filter.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
<?php
declare(strict_types=1);
// all posts whose author is somebody called "john"
return [
'SELECT post1, user1 FROM GraphQLTests\Doctrine\Blog\Model\Post post1 INNER JOIN post1.user user1 WHERE user1.name LIKE :filter1',
GraphQLTests\Doctrine\Blog\Model\Post::class,
[
'groups' => [
[
'groupLogic' => 'AND',
'conditionsLogic' => 'AND',
'joins' => [
'user' => [
'type' => 'innerJoin',
'conditions' => [
[
'name' => [
'like' => [
'value' => '%john%',
'not' => false,
],
],
],
],
],
],
],
],
],
[],
];