• this is only a guess, because you did not specify enough details. the desired results did not show where the values might have come from, and since BOTH queries report the same columns, whether that is used to join the two together, or just add the values together, or what.

    this is just to make you think about the query a little better;

    this is doing a cross join, but your data seems to be assuming one row at a time(is this in a cursor? there's a better way to do this)

    SELECT T2.KWMENG,

    T1.NETWR + T2.NETWR,

    T1.NTGEW,

    T1.MATNR + T2.MATNR,

    T1.AUDAT,

    T1.KUNNR

    FROM

    (

    Select KWMENG, NETWR, NTGEW, MATNR, AUDAT, KUNNR from vbap where matnr = 'FG153765464081221' and KUNNR = 'HA127' and AUDAT >= '2013-01-01 00:00:00.000' AND AUDAT <= '2013-02-13 00:00:00.000'

    ) T1,

    (

    Select FKIMG, NTGEW, NETWR, MATNR, FKDAT, KUNRG from SALES_DATA where FKDAT >= '2013-01-01 00:00:00.000' AND FKDAT <= '2013-02-13 00:00:00.000' and AUBEL = '0000042644' and AUPOS = '110'

    )T2

    Lowell


    --help us help you! If you post a question, make sure you include a CREATE TABLE... statement and INSERT INTO... statement into that table to give the volunteers here representative data. with your description of the problem, we can provide a tested, verifiable solution to your question! asking the question the right way gets you a tested answer the fastest way possible!