tmenier / AsyncPoco

A long-"awaited" fully asynchronous PetaPoco fork
Other
127 stars 33 forks source link

Replaced the @ sign with the : sign for the primary key value referen… #39

Closed jonast92 closed 6 years ago

jonast92 commented 6 years ago

…ce in the BuildPrimaryKeySql method. It was using the @ identifier to assign the value for which primary key to reference. This caused the UpdateAsync(poco) method to not work for Oracle applications because the OracleCommand.Parameters Property requires a : sign, according to the official msdn documentation (https://msdn.microsoft.com/en-us/library/system.data.oracleclient.oraclecommand.parameters.aspx).

lajjts commented 6 years ago

I hope all is well, @tmenier. Is it possible for you to check the impact on the code for your DBRM of choice that this PR would have? It appears to be crucial for Oracle statements as explained. I have to use a utility method within my projects to construct the Sql from scratch from the pogos to include ':' instead of '@' for the primary key value reference, it's not very feasible in the long run.

tmenier commented 6 years ago

I can't accept this because it causes all database tests to fail on all non-Oracle platforms. It's an Oracle-specific bug that needs an Oracle-specific solution. I'll look into it.

tmenier commented 6 years ago

@jonast92 @lajjts A fix for this is now available:

https://www.nuget.org/packages/AsyncPoco/1.2.1

Please let me know if this resolves the issue for you.