‎2018 Oct 03 10:11 PM
dears ,
i have a statement using inner and left join but the left join not working because it give me all data , it is assumed select all data except the data on left join table ,this is a statement for any one can help me ,thanks.
SELECT h.StoreId , convert(varchar, h.Time, 112), datepart(hh, h.Time), ( l.Quantity * l.price ) as Sales, l.SalesTax as Tax, h.TransactionNumber , l.AutoID, l.quantity
FROM [dbo].[Transaction] as h
inner join [dbo].[TransactionEntry] as l
on h.TransactionNumber = l.TransactionNumber
and h.StoreID = l.StoreId
left join [dbo].[SAP_UploadedAutoIDs] as sa
on l.autoid = sa.autoid
where h.Time = '03-10-2018 00:00:00'
‎2018 Oct 04 7:19 AM
If your DB is Oracle, I suggest you ask on an Oracle forum. If it's HANA; then you want the HANA tag. This isn't an ABAP question - it's an SQL question. The fact that you're using ABAP EXEC to run it is kind of irrelevant.