David, Si Chen,

Just to let you know my impression as an observer of this thread.

I was shocked to read "the +/- notation does not work well with PostgreSQL". Was bracing myself for a tidal wave of a change in the OFBiz framework.

Jonathon

David E. Jones wrote:

On Feb 5, 2007, at 10:16 AM, Si Chen wrote:

David E. Jones wrote:

Hold on a minute there.... did you actually test and find this to be a problem? The +/- notation is an entity engine ONLY thing and should never make it to the database.

This patch should be reverted and if +/- are making it to the database instead of being replaced with an ASC/DESC by the entity engine then THAT bug should be fixed.

This is a slippery slope and we should backup to the top before it gets going...

-David

On Feb 2, 2007, at 6:16 PM, [EMAIL PROTECTED] wrote:

Author: sichen
Date: Fri Feb  2 17:16:36 2007
New Revision: 502824

URL: http://svn.apache.org/viewvc?view=rev&rev=502824
Log:
Fix a pretty significant bug with sequence of inventory item reservations for orders: FIFO and LIFO were reversed (I checked this) and the +/- notation does not work well with PostgreSQL

Modified:
ofbiz/trunk/applications/product/script/org/ofbiz/product/inventory/InventoryReserveServices.xml

Modified: ofbiz/trunk/applications/product/script/org/ofbiz/product/inventory/InventoryReserveServices.xml

David,

I worked on this with Leon, and we did test this a few times, and the inventory reservation sequence was wrong. Previously when using the FIFO reservation, the last item received was being reserved against orders. It seems that "-datetimeReceived" was ordering them by descending order of date time received, and as a result reservations were done in the wrong sequence.

We did not realize that the + or - notation were an entity engine thing, but please test the actual reservation of inventory before and after this patch and let us know which behavior you feel is correct. I realize this is a pretty basic fix to an existing feature, and I had trouble believing that something like this could be broken, but we did try it several times ourselves.
Si

Perhaps I should have been more explicit in my comment. I was referring only to the apparent bug report about the +/- notation on certain databases, including Postgres.

My comments did not mention nor had anything to do with the fix of the inventory reservation sequence, and it's great that you guys found and fixed that bug. It looks like the _REC reserve orders were added to the original code but not implemented correctly, so yeah, it's great that you took care of that.

-David


Reply via email to