SQL code for showing difference between two records

mysql sql

22 просмотра

1 ответ

I have a question about a SQL statement. And I hope I am able to explain it the right way so you can understand it.

I have a table where with articlecode, description, retailprice and sellingprice. Now I have to show only the record where retail price and selling price have a difference between them of €150.

So I started to think I could I do it? (Yes I am new to SQL)so:

SELECT articlecode, description, retailprice, sellingprice  
FROM article 
WHERE retailprice (and here I do not know).

Hopefully you can help me.

Автор: GLRotterdam Источник Размещён: 08.11.2019 11:17

Ответы (1)


0 плюса

It will be like this:

SELECT articlecode, description, retailprice, sellingprice  
FROM article 
WHERE sellingprice-retailprice = 150
Автор: Partha Mitra Размещён: 20.08.2016 12:54
Вопросы из категории :
32x32