Добавил:
Опубликованный материал нарушает ваши авторские права? Сообщите нам.
Вуз: Предмет: Файл:
Firebird Null guide.pdf
Скачиваний:
8
Добавлен:
23.08.2013
Размер:
78.64 Кб
Скачать

Firebird Null Guide

NULL behaviour and pitfalls in Firebird SQL

Paul Vinkenoog

15 April 2005 - Document version 0.2

Table of Contents

 

Introduction ......................................................................................................................

3

What is NULL? .................................................................................................................

3

NULL in expressions .........................................................................................................

3

Expressions returning NULL ......................................................................................

4

NULL in boolean expressions ....................................................................................

4

More logic (or not) ....................................................................................................

5

NULL in aggregate functions .....................................................................................

6

NULL handling in UDFs ....................................................................................................

6

NULL <-> non-NULL conversions you didn't ask for ..................................................

6

Being prepared for undesired conversions ...................................................................

7

More on UDFs ..........................................................................................................

7

NULL in if statements .......................................................................................................

8

Testing if something is NULL ............................................................................................

8

Setting a field or variable to NULL .....................................................................................

9

Dealing with NULLs .........................................................................................................

9

Testing for NULL - if it matters ..................................................................................

9

Finding out if fields are the same ..............................................................................

10

Substituting NULL with a value ...............................................................................

11

Summary ........................................................................................................................

13

A. Document history ........................................................................................................

14

B. License notice .............................................................................................................

15

ii