• For the first, CROSS JOIN creates a CARTESIAN PRODUCT, which means you end up with ALL combinations of freight_manager and LargeOrderShippers!

    Alter your function to include something to bind freight_manager to shippers and order.

    Then call with either

    select     *

    from       freight_manager

    inner join dbo.LargeOrderShippers(min_value, max_value) AS los on los.someID = freight_manager.someID


    N 56°04'39.16"
    E 12°55'05.25"