필드명 addr이 1이고 addr2가 null이거나 빈칸일경우를 알고싶은데.. 이중 select해야되나요?
맨위 이미지 : 전체 테이블
마지막 이미지 : SELECT * FROM aaa WHERE addr='1' AND addr2='' OR addr2 IS NULL
SELECT * FROM (SELECT * FROM aaa WHERE addr2 IS NULL) WHERE addr2=''
에러메시지
Error Code : 1248
Every derived table must have its own alias
SELECT * FROM aaa WHERE addr2='' AND (SELECT * FROM aaa WHERE addr2 IS NULL)
에러메시지
Error Code : 1241
Operand should contain 1 column(s)
밑에 괄호 사용안하는건 에러가 나오네요.. 위에건 잘되요~ 고맙습니다
isnull붙일경우
에러메시지
Error Code : 1582
Incorrect parameter count in the call to native function 'ISNULL'
is null 띄어서 할 경우
에러메시지
Error Code : 1064
You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near 'IS NULL(addr2, '') = ''
LIMIT 0, 1000' at line 1