An email address.
At a glance
- Stored as: the value itself, written inline wherever it is used.
- Search: full-text (
~*); as one identifier, soilikepatterns match any part of it and full-text search sees it as one word.
Writing
Write the address as text: Jane.Doe+billing@Example.com. It is checked when it is
written and stored in lowercase, the whole address included: jane.doe+billing@example.com.
Spaces around it are dropped.
- The domain must be a real-looking one with a dot (
example.com);jane@exampleandjane@localhostare refused. - A
+tagafter the name is kept as part of the address, sojane+billing@example.comandjane@example.comare two different values. - An address that does not check out is refused with
Invalid email format: …orInvalid domain: ….
Written as
A JSON string whose schema format is email.
Reading
You read back the stored, lowercase address.
Querying
A value compared with = or in is checked and lowercased the same way first, so
Jane.Doe@Example.com finds jane.doe@example.com. A like or ilike pattern is used as
written, so match part of an address with ilike.
Party | email_addresses = "Jane.Doe@Example.com" | select id, full_names
A word search (~*) treats the whole address as one word, so it never finds part of
one. To find part of an address, such as everyone at one domain, use ilike. It
checks every row in scope, so narrow the query first on a large table.
Party | email_addresses ilike "%@example.com" | select id, email_addresses | limit 50
Every operator is in the HQL reference.
Operations
Through the dtypes resource: