Just discovered: This problem exists only when I use prepared queries. Same code without a prepared query works as expected. So definitely not my bug. I write a bug report. Guido