Re: ConnectionPooling and the new parameter_collection.cs
Posted by: Matt
Date: December 05, 2006 03:01PM

I had a similar error:

System.ArgumentException: Item has already been added. Key in dictionary: '?p7' Key being added: '?p7'

This error occurs in the following scenario:

In an invoicing app that I'm working on, a grid control for invoice items has these columns:

ID, InvNo, No, Description, Tax, Price, Qty, QtyC, Amount

The QtyC column is the same as Qty. It is used to compare the quantity entered with the quantity as it were, the last time the record was saved, for updating the inventory. This is the column that gave me trouble when saving.

Originally, I selected: SELECT ... Price, Qty, Qty AS QtyC, Amount ... since QtyC doesn't exist in the table. When updating, I think the error was generated because Qty is listed twice. To solve this problem, I changed the select to: SELECT ... Price, Qty, CONCAT(Qty) AS QtyC, Amount ...

I don't know why adding CONCAT works, but it does.

Options: ReplyQuote


Subject
Written By
Posted
Re: ConnectionPooling and the new parameter_collection.cs
December 05, 2006 03:01PM


Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.