Page 1 of 1

3.0.16 => 4.2 transition

Posted: Fri 09 Aug 2013 13:19
by listonic
I am using Linq Connect 3.0.16, i tried to upgrade to 4.2.306.

I have my custom DataProvider which Extends SqlDataProvider and method

protected override IDbCommand CreateCommand(string commandText, IDbConnection connection, bool forBatch)

However this method does not exist in SqlDataProvider in 4.2.306.

How to create same module in version 4.2.306 (a way to provide custom implementation of IDbCommand? )

Regards
Piotr Wójcicki

Re: 3.0.16 => 4.2 transition

Posted: Mon 12 Aug 2013 10:41
by MariiaI
Thank you for the report on this. This issue relates to the fact that we have made a major refactoring of the LinqConnect engine since version 4.0.10. We are investigating this issue and inform you about the results as soon as possible.
Please also tell us if you lack some other features in the new version of LinqConnect.

Re: 3.0.16 => 4.2 transition

Posted: Thu 15 Aug 2013 14:06
by listonic
So basically it is impossible to do what i need with the new version?

Seriously, not proffesional.

Re: 3.0.16 => 4.2 transition

Posted: Fri 16 Aug 2013 08:38
by MariiaI
We have made changes for this issue and the CreateCommand(string commandText, IDbConnection connection, bool forBatch) method will be available since the next build of LinqConnect.
We will inform you when new build of LinqConnect is available for download.

Re: 3.0.16 => 4.2 transition

Posted: Tue 20 Aug 2013 06:12
by MariiaI
The bug with missing CreateCommand method in the DataProvider class is fixed. The fix will be included in the next build of LinqConnect. We will inform you when it is available for download.

Re: 3.0.16 => 4.2 transition

Posted: Fri 06 Sep 2013 07:36
by Helen
New build of LinqConnect 4.2.327 is available for download now!

It can be downloaded from http://www.devart.com/linqconnect/download.html (trial version) or from Registered Users' Area (for users with active subscription only).
For more information, please refer to http://forums.devart.com/viewtopic.php?f=31&t=27873 .

Re: 3.0.16 => 4.2 transition

Posted: Thu 19 Sep 2013 10:57
by listonic
One more question. How can you provide custom sqlcommand implementation while using POCO Entities template ?

The generated context does not seem to respect [ProviderAttribute] so i cannot provide custom SqlDataProvider.

Re: 3.0.16 => 4.2 transition

Posted: Thu 19 Sep 2013 14:08
by MariiaI
listonic wrote:The generated context does not seem to respect [ProviderAttribute] so i cannot provide custom SqlDataProvider.
'POCO entity' template generates the LinqConnect-independent (persistence-ignorant) classes. This template doesn't generate attributes, EntitySet and EntityRef for navigation properties, etc.
listonic wrote:How can you provide custom sqlcommand implementation while using POCO Entities template?
You can specify it in the mapping file - YourDataContext.xml file - which should be created when you're using "POCO Entity" template. It is necessary to specify the name of the provider, the assembly, the version if required. Make sure that the necessary assembly is available in your project.

If you have any further questions, feel free to contact us.

Re: 3.0.16 => 4.2 transition

Posted: Thu 26 Sep 2013 12:14
by listonic
I have one more significant problem with this new version of LinqConnect

To update entity with identity column, i used to create an object of generated class, set all fields (including identity key), then attaching the object to conetxt setting modified flag to true (Context.Attach(object, true)) and then submiting context changes.

This updated the entity.

Now all identity fields are generated as readonly and if i change it to not readonly, they are beeing included in an update statement, and obviously you cant update identity field which is a key.

How should i proceed to use the new version same way as i am used to ?

I other words, how do i update or delete entity without loading it from database first ?

Regards
Piotr

Re: 3.0.16 => 4.2 transition

Posted: Fri 27 Sep 2013 10:26
by MariiaI
Thank you for the report. We have reproduced the issue with ignoring IsDbGenerated=true when using Attach(TEntity entity, bool asModified). We will investigate it and inform you about the results as soon as possible.

Re: 3.0.16 => 4.2 transition

Posted: Fri 27 Sep 2013 10:28
by listonic
Answer the question. How to update the entity without fetching it from database first.

Re: 3.0.16 => 4.2 transition

Posted: Fri 27 Sep 2013 12:23
by MariiaI
You could try performing it via the Attach(TEntity entity, TEntity original) method. For example:

Code: Select all

TestMDataContext context = new TestMDataContext() { Log = Console.Out };
TestID test_new = new TestID()
{
  Id = 1,
  Value = "new value"
};   
TestID test_original = new TestID()
{
  Id = test_new.Id
};
context.TestIDs.Attach(test_new, test_original);
context.SubmitChanges();

Please refer to http://www.devart.com/linqconnect/docs/ ... tml#modify.

Re: 3.0.16 => 4.2 transition

Posted: Fri 27 Sep 2013 12:30
by listonic
Ok guys, You just lost a customer.

Everytime you change a major version number of linq connect you f.. everything up.

My whole code suddenly stops working. Same was when you updated from 2.x.x to 3.x.x. I spent 3 monhts reporting bugs to you.

You mess up all interfaces and you do not perform any testing procedures.

Using Attach method with modify flag true is most basic method for me. I have no idea how could you mess it up.

Fortunatelly i have high level of abstraction in my application, which as we can see you do not want to support, and switching to for example Entity Framework is not a big deal for me.

Farewell.

Re: 3.0.16 => 4.2 transition

Posted: Fri 27 Sep 2013 13:18
by MariiaI
We are sorry that you are not satisfied with our product and will do our best to correct the situation.
We will fix this issue and inform you when the corresponding build of LinqConnect is available for download.

Re: 3.0.16 => 4.2 transition

Posted: Fri 18 Oct 2013 05:12
by MariiaI
The bug with ignoring 'IsDbGenerated = True' when using Attach(TEntity entity, bool asModified) method is fixed.
New version of LinqConnect 4.3 is available!
It can be downloaded from http://www.devart.com/linqconnect/download.html (trial version) or from Registered Users' Area (for users with active subscription only).
For more information, please refer to http://forums.devart.com/viewtopic.php?f=31&t=28128.