Closed. This question needs debugging details . It is not currently accepting answers.
Edit the question to include desired behavior, a specific problem or error, and the shortest code necessary to reproduce the problem . This will help others answer the question.
Closed 5 days ago.
The community is reviewing whether to reopen this question as of 5 days ago.
Improve this question
I am trying to do a HTML table but i am having troubles where it does not return a value. This example shows my result. Sample Image
Is it possible to script that if there isnt any result, it will return 0?
I tried ISNULL
method and it does not return me any values.
I am expecting that by using the ISNULL
method, it will return a 0 in the result, but it doesn't do so.
SELECT
ISNULL(body, 0)
FROM
[EMAIL_MATRIX]
WHERE
body NOT IN (SELECT c.Body
FROM [dbo].[EMAIL_DETAILS] a
INNER JOIN [Email_matrix] c ON SUBSTRING(a.Subject, 5, LEN(a.Subject) - 4) = c.Subject
AND a.Body LIKE CONCAT('%', c.body, '%')
WHERE CAST(a.Send AS DAte) = '2022-10-04')
2条答案
按热度按时间vwoqyblh1#
Try this:
piv4azn72#
Try this,