Re: int8 primary keys still not using index without manual
| От | Tino Wildenhain |
|---|---|
| Тема | Re: int8 primary keys still not using index without manual |
| Дата | |
| Msg-id | 3FABB625.9070500@wildenhain.de обсуждение исходный текст |
| Ответ на | Re: int8 primary keys still not using index without manual ("Craig O'Shannessy" <craig@ucw.com.au>) |
| Ответы |
Re: int8 primary keys still not using index without manual
Re: int8 primary keys still not using index without manual |
| Список | pgsql-general |
Hi Craig, Craig O'Shannessy schrieb: > I'm using EJB CMP (Enterprise Java Beans, Container Managed Persistence), > so the SQL is generated. I would think this is a common usage of > PostgreSQL, as a database for a modern EJB container. There are options > for fixing this (not including fixing postgres itself), IMHO the best is > patching the JDBC PreparedStatement code so that setLong() adds '::int8'. > The advantage here is that you can use hand coded prepared statements, as > well as auto CMP ones, and both will get the proper cast. > > The real problem is that PostgreSQL out of the box is not really usable > for CMP! This really isn't good, and I'm always suprised that it's not > fixed. It was very luck we found the bug on the website when we were > evaluating PostgreSQL against Oracle, it wasn't easy to track down or fix, > and it causes truly horrible performance problems. > > I spose you'd call it my pet peeve. > I agree with you wholeheartly - it also bothers me why postgresql can cast [0-9]+ to int4, but only '[0-9]+' to int8 or int2, I really cannot see the difference. Any ideas where we have to look for the place to patch? Regards Tino
В списке pgsql-general по дате отправления: