Hello Jay,
This is actually a documented problem with DBD::Informix and blobs;
DBD::Informix cannot update a blob ("TEXT") field in a query, and the only
current workaround is to do a delete, then insert. I have attached the
relevant section from the DBD::Informix man page. This would probably require
a patch to Apache::Session to detect if the driver is Informix and change the
sql accordingly.
Carl Tichler
--------------------------------------------------
Issue: The Informix engines give no support for
determining the types of input parameters except in the
VALUES clause of an INSERT statement. This means that
DBD::Informix cannot handle blobs in the SET clause of an
UPDATE statement. The only known way to deal with this is
to use a SELECT to retrieve the old data, a DELETE to
remove it, and an INSERT to replace it with the modified
data. Not nice, but it works.
Jay Jacobs writes:
> I've been fighting with Apache::Session and Informix... I've been using
> Apache::Session ver 1.03 (knowing that 1.5x isn't "appropriate" for
> informix) and Informix Dynamic server 2000 9.2. Everything else is the
> latest version, and on suse 6.4
>
> At first it would hang up when trying to re-tie to a session. Then I set
> AutoCommit=>1 and RaiseError=>0 on the Apache::Session connection, and I
> get an error:
>
> execute failed: SQL: -608: Illegal attempt to convert Text/Byte blob type.
>
> ...any time the "update" is called from Apache::Session, and nothing is
> updated. I've tried switching the text field to a blob, (always storing
> in the table).
>
> Has anyone gotten this to work at all? There's been a motion to get mysql
> running to do sessions, which strikes a bad chord with me...
>
> Jay Jacobs
>