id summary reporter owner description type status priority component severity resolution keywords cc release 4805 [Patch] ClientsPlugin not working with Postgres 8.3 (possibly other versions) as trac backend scott.mead@… "The clientsplugin is emitting some SQL that is bad when it comes to postgresql 8.3 (haven't tried with lower versions, it may be the same). I have modified the api.py and model.py files to try and make this work. The 'broken' behavior is as follows: * Cannot upgrade During inital schema creation, a rollback is being issue when trying to populate the 'client_events' table. This is because surrounding a string with a "" (double quote) in postgres is just asking for a column. The solution was to change the "" to ' (double quotes to single quotes). [source:/clientsplugin/0.11/clients/api.py@4486#L89 API.PY Line 89-101] * Next, the problem is that during client 'creation' (via webadmin) there was an error being thrown: {{{ """" Invalid input syntax for INTEGER }}} After tracing, I found that the 'self.default_rate' and 'self.currency' variables where being defaulting to ' ' (empty string) if not found. I changed this to default to 0. [[BR]] [source:/clientsplugin/0.11/clients/model.py@4486#L37 MODEL.PY Line 37-38] * The last problem was on updating the client, if you erased the '0' in the billrate box, and submitted, you would get the same error as before. I just added to checks (one for default_rate and one for currency) right before the execution of the UPDATE statement.[[BR]] [source:/clientsplugin/0.11/clients/model.py@4486#L95 MODEL.PY Line 95] This is working on my setup now, but there are a couple of things to note: * It was a new setup with no existing tickets * PostgreSQL 8.3.6 * Trac being run through apache with ldap based authentication If you have questions or want more info, please feel free to contact me. " defect new normal ClientsPlugin normal clientsplugin postgres 0.11