Checking whether or not an item is currently in-transit using SQL is more complicated than one would like. We know an item is currently in-transit if there is a line in branchtransfers with that itemnumber, with a date sent, and without either a date cancelled or a date received. I suggest we add a field to items that would work like items.onloan does for issues. We name the field items.intransit and when the transfer is sent we put something in the field (either the transfer ID or the branch to which the item is headed) and when the transfer is either completed or cancelled we null items.intransit.