Search found 2 matches

by matt_lethargic
Tue 06 Apr 2010 09:10
Forum: dotConnect for MySQL
Topic: Membership not login me in
Replies: 23
Views: 11004

Thanks for the reply

Have just tried the code you gave, status is Successful, but isValid is false. Have creating tried with a few different users and varified that they have entries in the db

Could it be that my schema is wrong in my db??
I can't remember how I created it, is there a script to build this again?

My membership schema:

Code: Select all

CREATE TABLE  `data`.`aspnet_users` (
  `userid` varchar(40) NOT NULL,
  `applicationname` varchar(255) NOT NULL,
  `username` varchar(245) DEFAULT NULL,
  `lastactivitydate` datetime DEFAULT NULL,
  `isanonymous` tinyint(4) DEFAULT NULL,
  PRIMARY KEY (`userid`),
  UNIQUE KEY `aspnet_users_username_pk` (`username`,`applicationname`)
) ENGINE=InnoDB DEFAULT CHARSET=latin1;


CREATE TABLE  `data`.`aspnet_membership` (
  `userid` varchar(40) NOT NULL,
  `password` varchar(255) DEFAULT NULL,
  `email` varchar(255) DEFAULT NULL,
  `passwordquestion` varchar(255) DEFAULT NULL,
  `passwordanswer` varchar(255) DEFAULT NULL,
  `comments` varchar(255) DEFAULT NULL,
  `isapproved` tinyint(4) DEFAULT NULL,
  `islockedout` tinyint(4) DEFAULT NULL,
  `creationdate` datetime DEFAULT NULL,
  `lastlogindate` datetime DEFAULT NULL,
  `lastpasswordchangeddate` datetime DEFAULT NULL,
  `lastlockoutdate` datetime DEFAULT NULL,
  `failedpasswordattemptcount` int(11) DEFAULT NULL,
  `failedpasswordattemptstart` datetime DEFAULT NULL,
  `failedpasswordanswercount` int(11) DEFAULT NULL,
  `failedpasswordanswerstart` datetime DEFAULT NULL,
  PRIMARY KEY (`userid`),
  CONSTRAINT `aspnet_membership_userid_ref` FOREIGN KEY (`userid`) REFERENCES `aspnet_users` (`userid`) ON DELETE CASCADE
) ENGINE=InnoDB DEFAULT CHARSET=latin1;
by matt_lethargic
Wed 31 Mar 2010 13:22
Forum: dotConnect for MySQL
Topic: Membership not login me in
Replies: 23
Views: 11004

Membership not login me in

dotConnect for MySQL 5.70 Beta
Visual Studio 2010 RC
ASP.NET 4

Hi,

I'm trying to get membership working with the above configuration ready for the start of our next project (officially kicking off when VS2010 and dotConnect MySQL 5.70 final are released), but am having minor problems.

I've got membership and roles working, I can add users/roles etc in the ASP.NET Configuration, but when I then try logging in using either the login control or Membership.ValidateUser() it always fails.

My config:

Code: Select all


      
        
        
      
    


      
        
        
      
    


      
    
Any ideas anyone?