Skip to content

Commit c2a90f8

Browse files
committed
Backup
1 parent 483e693 commit c2a90f8

File tree

2 files changed

+98
-1
lines changed

2 files changed

+98
-1
lines changed

docs/wiki/v1/streams.md

Lines changed: 97 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,103 @@ So how does PartiQL read values from a stream into Datums, and how does it handl
2828
encoding may include a data type or it may not. Also, the reader itself may expect a type (or not). Consider that a
2929
PartiQL value carries a type with it along with the value itself.
3030

31+
## Type Syntax
32+
33+
PartiQL values can be annotated with their exact types; this section defines the type annotation syntax.
34+
35+
```
36+
type_t ::= bool_t
37+
| tinyint_t
38+
| smallint_t
39+
| int_t
40+
| bigint_t
41+
| numeric_t
42+
| decimal_t
43+
| float_t
44+
| real_t
45+
| double_t
46+
| char_t
47+
| varchar_t
48+
| string_t
49+
| blob_t
50+
| clob_t
51+
| date_t
52+
| time_t
53+
| timez_t
54+
| timestamp_t
55+
| timestampz_t
56+
| array_t
57+
| bag_t
58+
| struct_t
59+
| variant_t
60+
61+
bool_t ::= 'bool'
62+
63+
tinyint_t ::= 'tinyint'
64+
65+
smallint_t ::= 'smallint'
66+
67+
int_t ::= 'int'
68+
69+
bigint_t ::= 'bigint'
70+
71+
numeric_t ::= 'numeric' '(' uint ',' uint ')'
72+
73+
decimal_t ::= 'decimal' '(' uint ',' uint ')'
74+
75+
float_t ::= 'float' '(' uint ')'
76+
77+
real_t ::= 'real'
78+
79+
double_t ::= 'double'
80+
81+
char_t ::= 'char' '(' uint ')'
82+
83+
varchar_t ::= 'varchar' '(' uint ')'
84+
85+
string_t ::= 'string'
86+
87+
blob_t ::= 'blob' '(' uint ')'
88+
89+
clob_t ::= 'clob' '(' uint ')'
90+
91+
date_t ::= 'date'
92+
93+
time_t ::= 'time' '(' uint ')'
94+
95+
timez_t ::= 'timez' '(' uint ')'
96+
97+
timestamp_t ::= 'timestamp' '(' uint ')'
98+
99+
timestampz_t ::= 'timestampz' '(' uint ')'
100+
101+
array_t
102+
::= 'array'
103+
| 'array' '<' type_t '>'
104+
| 'array' '<' type_t '>' '(' uint ')'
105+
106+
bag_t
107+
::= 'bag'
108+
| 'bag' '<' type_t '>'
109+
| 'bag' '<' type_t '>' '(' uint ')'
110+
111+
struct_t
112+
::= 'struct'
113+
| 'struct' '<' struct_t_fields '>'
114+
115+
struct_t_fields ::= struct_t_field (',' struct_t_field )
116+
117+
struct_t_field ::= name ':' type_t
118+
119+
variant_t ::= 'variant' '(' name ')'
120+
121+
uint = [0-9]+
122+
123+
name = [A-Za-z]
124+
```
125+
126+
> This does NOT include things like union types, map types, and the row type.
127+
31128
## Writing Data
32129

33130
### PSink

partiql-spi/src/main/java/org/partiql/spi/stream/PSink.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -150,7 +150,7 @@ default void flush() {
150150
/**
151151
* Step into container, given as PType code.
152152
*/
153-
void stepIn(@NotNull int container);
153+
void stepIn(int container);
154154

155155
/**
156156
* Step out of container type.

0 commit comments

Comments
 (0)