Nested transactions are not supported.
Hi,
After looking for an answer almost the whole day and didn't find a proper solution I decided to post a questions here.
Actually my post relates to another one on the forum which was not answered:
http://forums.mysql.com/read.php?38,393030,393030(neither of recommendations listed helped a lot)
But my code looks a bit different:
using (TransactionScope txScope = new TransactionScope())
{
MembershipUser mu = null;
try
{
mu = Membership.CreateUser(login, password, email);
}
catch(Exception ex)
{
throw ex;
}
txScope.Complete();
}
Exception "Nested transactions are not supported." is thrown after this line is executed:
mu = Membership.CreateUser(login, password, email);
Some info about the environment:
Web.config
<add name="LocalMySqlServer"
connectionString="Datasource=localhost;Database=[dbname];uid=[user_id];pwd=[password];"
providerName="MySql.Data.MySqlClient"/>
--------------
<membership defaultProvider="MySqlMembershipProvider">
<providers>
<clear />
<add name="MySqlMembershipProvider"
type="MySql.Web.Security.MySQLMembershipProvider, MySql.Web,Version=6.3.7.0, Culture=neutral, PublicKeyToken=c5687fc88969c44d"
connectionStringName="LocalMySqlServer"
enablePasswordRetrieval="false"
enablePasswordReset="true"
requiresQuestionAndAnswer="false"
requiresUniqueEmail="true"
passwordFormat="Hashed"
maxInvalidPasswordAttempts="5"
minRequiredPasswordLength="6"
minRequiredNonalphanumericCharacters="0"
passwordAttemptWindow="10"
applicationName="/"
autogenerateschema="true" />
</providers>
</membership>
As you can see I am using MySQL Connector Net 6.3.7 which should have this issue fixed.
MySql server version is 5.5
.NET 4.0
Any clue will be helpful.
Thanks.