Creating an array from Mysql table using $wpdb


I have a mysql table with a column names saying “Room_numbers” and “SessionID”‘s, so what i would like to do is create a simple array displaying all room numbers within the SessionID.

Something like
arrayroom = [12, 23, 45, 34] where as 12,23,45 and 34 are room numbers,

Im using wpdb-> method as it is a wordpress template page.

Thanks guys

Prash 3 years 2020-06-05T06:11:11-05:00 0 Answers 91 views 0

Leave an answer