Skip to content

Instantly share code, notes, and snippets.

View ngzax's full-sized avatar
😎
delivering!

Daryl Richter ngzax

😎
delivering!
View GitHub Profile

Keybase proof

I hereby claim:

  • I am ngzax on github.
  • I am ngzax (https://keybase.io/ngzax) on keybase.
  • I have a public key whose fingerprint is 4A4A 7D36 1872 E5A1 4F15 171A 9E6F B143 EAD5 8070

To claim this, I am signing this object:

@ngzax
ngzax / index_dupes.sql
Last active August 29, 2015 14:06 — forked from jberkus/gist:e4cadd6b8877c3bc59c8
Finds duplicate indexes on a PostgreSQL DB
-- check for exact matches
WITH index_cols_ord as (
SELECT attrelid, attnum, attname
FROM pg_attribute
JOIN pg_index ON indexrelid = attrelid
WHERE indkey[0] > 0
ORDER BY attrelid, attnum
),
index_col_list AS (
SELECT attrelid,
@ngzax
ngzax / Lucida Sans Typewriter-Powerline.otf
Created June 7, 2012 15:26
Lucida Sans Typewriter patched for Powerline
foreach ($array as $key => $value) {
if (is_null($value) || $value=="") {
unset($array[$key]);
}
}