Here is my mind map. It shows that the fields in the table Match team_one and team_two refer to the Team table by the id field, i.e. connection occurs. From the name of the tables, we can conclude that the Match table is a table that displays matches, and the Team table is a list of teams. 
I have this form
<form action="{{ route('match.store') }}" method="POST"> {{ csrf_field() }} <div class="uk-margin"> <input type="hidden" value="{{ Auth::id() }}" class="uk-input" name="user_id"> </div> <!-- foreach --> <div class="uk-margin"> <label class="uk-form-label">Выбор первой команды</label> <select name="team_one" class="uk-select"> @foreach($teams as $team) <option value="{{ $team->id }}">{{ $team->id }}. {{ $team->name }}</option> @endforeach </select> </div> <div class="uk-margin"> <label class="uk-form-label">Выбор второй команды</label> <select name="team_two" class="uk-select"> @foreach($teams as $team) <option value="{{ $team->id }}">{{ $team->id }}. {{ $team->name }}</option> @endforeach </select> </div> <div class="uk-margin"> <label class="uk-form-label">Сатус матча</label> <select name="status" class="uk-select"> <option value="1">Предстоящий матч</option> <option value="2">Текущий матч</option> <option value="3">Прошедший матч</option> </select> </div> <div class="uk-margin"> <label for="factor" class="uk-form-label">Factor</label> <input id="factor" type="text" class="uk-input" value="Disable" name="factor"> </div> <div class="uk-margin"> <button type="submit" class="uk-button uk-button-secondary">Добавить</button> </div> </form> The form adds an entry to the Match table. Now the question arises, how can I display the data from the Match table, let me remind you that in this table there is no team name (Team table), but only the numbers of these teams. I need to get data from the Match table, with data commands, i.e. for example, the team_one array contains the data of one team, and the team_two array contains the data of the second team. in one sql code, desirable.
Team.id=Match.team_one OR Team.id=Match.team_twoand you have exactly 2 entries at the output of the query. Each line contains data from one of the commands. Considering that fetch just creates an array, it turns out that you read 2 records in 2 different arrays and everything you wanted. in addition, you can addorder by (Team.id=Match.team_two)and the first team as a result will always be in the first record, the second in the second, you will not confuse - Mike$arr[0]->name .... $arr[1]->name(if you have strings in an array of course) - Mike