I have an array which is result of a query.
r = [
#<Reservation id: 27, schedule_id: 1, name: "test user", gender: "no_answer",
reservation_num: 1, zip: "", prefecture: "", address: "", street: "",
tel: "", note: "", satisfied: true, canceled: false, seq: 27,
created_at: "2019-08-28 06:04:30", updated_at: "2019-08-28 06:04:30",
created_by: 2, updated_by: 2, from_partner: false, no_counting: false,
reservation_time: nil, one_day_payment: nil, payment_id: 123456>
]
I want to get the payment_id but don't understand how should I write.