Never mind, found the solution. In a one to many relationship you have to include the foreign key in the with clause. I saw no mention of this in the documentation.
Here is what worked:
Booking::with('bookingLines:id,booking_id')->first();
Hope this helps someone else.
Sign in to participate in this thread!
The Laravel portal for problem solving, knowledge sharing and community building.
The community