Hi,

(I've had a bit of a search, but i'm not exactly sure what to call this, so its hard to search for)

Consider this,

I have 3 tables, a table or "orders", and two seperate "product" tables

Tables -
Orders
Modems
Accessories

The orders table has a "type" column, the type changes which product table I need to join to, the order table also has a "product id" column

eg, a row in the Orders table with the type as "Modems" means I need to join to the modems table to get the details for the particular product.

Is it possible to create a single query to join against the required tables conditionally? Rather than doing it as a heap of unions?

Cheers.