Puas yog null vs IsNull?
Puas yog null vs IsNull?

Video: Puas yog null vs IsNull?

Video: Puas yog null vs IsNull?
Video: ЗАКРИЧАЛ – ПОТЕРЯЛ ₽200.000 / ТРЭШКЭШ: Тишина 2024, Kaum ib hlis
Anonim

Yog Null thiab IsNull () ob leeg nrhiav null muaj nuj nqis, tab sis koj yuav tsis siv lawv tib txoj kev. Koj yuav siv Yog Null thiab yog Tsis Null hauv query expressions thiab SQL WHERE clauses. IsNull (), ntawm qhov tod tes, yog Visual Basic for Applications (VBA) muaj nuj nqi thiab tsuas yog siv hauv VBA modules xwb.

Ib yam li ib tug yuav nug, Isnull txhais li cas?

Txhais thiab siv The ISNULL () muaj nuj nqi xa rov qab tus nqi teev yog tias cov lus qhia yog NULL . Yog hais tias qhov kev qhia yog TSIS TAU NULL , qhov no muaj nuj nqi rov qab qhia.

Qhov thib ob, yog NULL qhia hauv kev nkag? IsNull Function. Rov qab tus nqi Boolean uas qhia tias yog ib qho kev qhia tsis muaj cov ntaub ntawv siv tau ( Null ). Cov lus qhia yuav tsum muaj yog Variant uas muaj tus lej kev qhia los yog txoj hlua kev qhia . IsNull rov muaj tseeb yog tias kev qhia yog Null ; txwv tsis pub, IsNull rov False.

Khaws qhov no hauv kev saib, puas yog null thiab tsis yog null hauv kev nkag?

MS Nkag mus IsNull() Function Lub IsNull() muaj nuj nqi xyuas seb puas muaj cov lus qhia Null ( tsis muaj cov ntaub ntawv). Txoj haujlwm no rov qab tus nqi Boolean. TRUE (-1) qhia tias cov lus qhia yog a Null tus nqi, thiab FALSE (0) qhia tias qhov kev qhia yog tsis yog a Null tus nqi.

Puas yog NULL Oracle muaj nuj nqi?

The NVL muaj nuj nqi tso cai rau koj hloov null tus nqi nrog tus nqi pib. Yog hais tias tus nqi nyob rau hauv thawj parameter yog null , cov muaj nuj nqi rov qab tus nqi nyob rau hauv qhov thib ob parameter. Peb paub tias COL1 hauv lub rooj xeem muaj null hauv txhua kab tsuas yog thawj. Siv NVL muaj nuj nqi peb hloov lub null tus nqi nrog 'ZERO'.

Pom zoo: