Page 1 of 1

initialize the datacontext with a different connectionstring

Posted: Sun 18 Apr 2010 08:47
by infinitep
How do I initialize the datacontext with a different connectionstring for Linq to MySQL?

If i pass a connectionstring to initialize the context it doesnt seem to work if the database name is different to the one the context was created with.

Thanks.

Posted: Mon 19 Apr 2010 09:51
by infinitep
I can live without this feature, the multiple selection (all in one properties editing) in the Entity Developer is more important than this. Part my bad on changing the development database to do a table comparission. Will restore the other way around for future compares.

Posted: Mon 19 Apr 2010 14:29
by AndreyR
There is a solution for the problem.
You should change the code generation template in the following way:
Replace the

Code: Select all

[Table(Name = @"")]
line with this one:

Code: Select all

[Table(Name = @"")]