Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

I want to collect all the names from table Bookings and WaitingList for a specif

ID: 3832513 • Letter: I

Question

I want to collect all the names from table Bookings and WaitingList for a specific flight(string) then order the names by timestamp but I don't know the proper sql/prepareStatement syntax. Can someone please help me

BOOKINGS connection prepa restatement ("SELECT FROM Bookings where flight elect All People and date prepare Statement SELECT* FROM Bookings where name BOOKINGID elect Bookings connection 79 elect Booking prepare Statement SELECT f FROM Bookings where name 80 connection and date NAME elect Booking SELECT bookingid FRO connection preparestatement Bookings where name and date FLIGHT 82 nsert Booking connection. prepare Statement Name, Flight, Date, timestamp VALUES INSERT INTO Bookings DATE emove Booking connection prepare Statement DELETE FROM Bookings where name and date 83 pdate Booking prepare Statement UPDATE Bookings set name where Booking and flight and date connection TIMESTAMP elect Names Waiting list where flight 85 connection prepare Statement SELECT name FROM Booking ORDER BY timestamp DESC ndexes 86 Foreign Keys 87 EE WAITINGLIST 88 (SQLException squException) wAITLISTID 89 iquException. printStackTrace(); NAME 91 ystem exit (1); FLIGHT 92 93 DATE getBooked Seats (String flight throws SQLException nt Date date ndexes tSet resultSet null Foreign Keys 96 Views Procedures Output Other schemas Flight Schedulersfs 5208 (run Java DB Database Process SQL 2 execution bc derby://localhost: 152 rs run ava. sgl.SQLSyntaxErrorException: Column name FLIGHT' is in more than one table in the FROM list n Repositories at org.apache.derby. client .am.SQLException Factory40.getSQLException (Unknown Source at org.apache.derby.client.am.SqlException.getSQLException (Unknown Source) on Builders at org. apache. derby.client.am. Connection .prepares tatement (Unknown Source at flightschedulersfs5208. Booking.

Explanation / Answer

Select name from Bookings where flight = ? UNION select name from WaitingList where flight = ? order by timestamp

Hire Me For All Your Tutoring Needs
Integrity-first tutoring: clear explanations, guidance, and feedback.
Drop an Email at
drjack9650@gmail.com
Chat Now And Get Quote