Custom Report Query for Sales Order?

My wish is to quantify how much inventory needed to be replenished according to unprocessed sales order if I don’t have enough on hand.

This is going to be addressed when warehousing module is implemented. It’s on the roadmap.

I was thinking along the line of JournalEntryLines. Is not currently possible for Sales Order? I tried SELECT * FROM SalesOrderLines. Since it returned error, I guess there’s no such table in database.