"Shuo Liu" <delphet@xxxxxxxxxx> writes: > One more question. I'm new to PostgreSQL and not an expert in debugging. After checking the manual, I think I need to turn on the following parameters in order to generate debug info. Do you think doing so would give us what we need to pinpoint the problem? > debug_assertions > trace_notify > trace_sort > debug_print_parse > debug_print_rewritten > debug_print_plan > debug_pretty_print If you can turn on debug_assertions, do so and see if it catches anything; but it's not enabled in a standard build, and if it is enabled it's on by default, so I doubt there's any win there unless you're prepared to rebuild Postgres from source. The others seem unlikely to be helpful for this problem. What would probably be most helpful is a stack trace, but that's not easy to get on Windows ... which is why the shortest route to a fix may well be to create a test case that someone can exercise on a more debug-friendly platform. If you got a stack trace, and it wasn't conclusive, we'd have to go in that direction anyway. regards, tom lane