Revision 2866
Added by Aaron Marcuse-Kubitza over 12 years ago
py_functions.sql | ||
---|---|---|
212 | 212 |
-- Name: _namePart_first; Type: INDEX; Schema: py_functions; Owner: bien; Tablespace: |
213 | 213 |
-- |
214 | 214 |
|
215 |
CREATE INDEX "_namePart_first" ON "_namePart" USING btree (first);
|
|
215 |
CREATE INDEX "_namePart_first" ON "_namePart" USING btree ((COALESCE(first, '\\N'::text)));
|
|
216 | 216 |
|
217 | 217 |
|
218 | 218 |
-- |
219 | 219 |
-- Name: _namePart_last; Type: INDEX; Schema: py_functions; Owner: bien; Tablespace: |
220 | 220 |
-- |
221 | 221 |
|
222 |
CREATE INDEX "_namePart_last" ON "_namePart" USING btree (last);
|
|
222 |
CREATE INDEX "_namePart_last" ON "_namePart" USING btree ((COALESCE(last, '\\N'::text)));
|
|
223 | 223 |
|
224 | 224 |
|
225 | 225 |
-- |
226 | 226 |
-- Name: _namePart_middle; Type: INDEX; Schema: py_functions; Owner: bien; Tablespace: |
227 | 227 |
-- |
228 | 228 |
|
229 |
CREATE INDEX "_namePart_middle" ON "_namePart" USING btree (middle);
|
|
229 |
CREATE INDEX "_namePart_middle" ON "_namePart" USING btree ((COALESCE(middle, '\\N'::text)));
|
|
230 | 230 |
|
231 | 231 |
|
232 | 232 |
-- |
233 | 233 |
-- Name: _namePart_unique; Type: INDEX; Schema: py_functions; Owner: bien; Tablespace: |
234 | 234 |
-- |
235 | 235 |
|
236 |
CREATE UNIQUE INDEX "_namePart_unique" ON "_namePart" USING btree (functions.ensure_not_null(first), functions.ensure_not_null(middle), functions.ensure_not_null(last));
|
|
236 |
CREATE UNIQUE INDEX "_namePart_unique" ON "_namePart" USING btree ((COALESCE(first, '\\N'::text)), (COALESCE(middle, '\\N'::text)), (COALESCE(last, '\\N'::text)));
|
|
237 | 237 |
|
238 | 238 |
|
239 | 239 |
-- |
Also available in: Unified diff
schemas/py_functions.sql: _namePart: Changed indexes to use `COALESCE` to match what sql_gen now does