Trying to apply amusarra's postgres patches. Starting with 9d482c703801c9d427bbb591e728a5c427f692e0