Dear JM,
Please see the following from the new guide which is for the upcoming
1.1.3pr2 release
CH2 CHANGING KEY VALUES IN INTERCEPTORS
Carlos Anjos points out that this can not be done.
Apparently if a field is marked with isKey="true" in the config file, the
preDelete and preUpdate methods disregard
any changes to it.
I had a situation where I did some processing in the preDelete method and
then I wanted to allow the operation, but
on a different row. So I changed the values in the fieldValues hashtable,
but still the orginal row got deleted.
After banging my head for where in my code the error was, I finally
understood that dbforms was ignoring the
change to that attribute. A friend of mine went through dbforms deleteEvent
code and confirmed that.
----- Original Message -----
From: "J M Okomba" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Wednesday, January 29, 2003 4:57 PM
Subject: [dbforms] Removing entry from fieldValues
>
> Using a preInsert (or preUpdate) I need to remove an entry from the values
> to be inserted (updated). So I do:
>
> fieldValues.remove("key");
>
> And when I do:
>
> System.out.println(fieldValues + " - fieldValues");
>
> I can see that the entry was removed.
>
> But dbforms still attempts to insert the value, causing an error.
>
> I there something I am missing out? I will appreciate any help.
>
>
> -------------------------------------------------------
> This SF.NET email is sponsored by:
> SourceForge Enterprise Edition + IBM + LinuxWorld = Something 2 See!
> http://www.vasoftware.com
> _______________________________________________
> DbForms Mailing List
>
> http://www.wap-force.net/dbforms
>
-------------------------------------------------------
This SF.NET email is sponsored by:
SourceForge Enterprise Edition + IBM + LinuxWorld = Something 2 See!
http://www.vasoftware.com
_______________________________________________
DbForms Mailing List
http://www.wap-force.net/dbforms