InstantForum 2012 - users cannot be found, cannot be PMed


InstantForum Problem
I posted a support ticket for this a week ago, bumped it a couple of times but no response, so hoping somebody here has an idea how to fix it.

We upgraded to IF 2012 a few months ago, had a few initial problems but then seemed to be working.

But not for new users, apparently. New users registering see an error message. It says it's logged, but I can't find any logs of what the error was. But the user does seem to be created, at least to some degree.

New users cannot PM, or be PMed. And as an admin, when I search for the users, the search doesn't find them. But they do exist as they can post.

Initially they could not post, as they couldn't confirm their signup (probably linked to issue of not being found in search), so we had to let everyone post without authorization/validation.

The whole upgrade process wasn't really as smooth as it should be, we were told we had to set default values on a whole list of tables manually, but this really should be in the SQL update scripts if it's required. I suspect there are other SQL hacks required which we haven't done so some table is failing, but without logs I'm just guessing.

The forum is kind of usable, but it's limping along, it's not great that new users get error messages on signup and cannot use lots of features, and now we've had to set everyone live from the start without approval, we not only get spammers, but we then cannot find/delete them easily because the admin search doesn't work.

I suspect what is happening is that some part of the account creation is failing, while some part is succeeded, so the new users end up incomplete in terms of required records. But I would have thought the user signup would be in a transaction to avoid this kind of thing.

Any help appreciated, i like the forum in general and it's really a lot of work for us to tear down and start with something else so I really hope it's not beyond repair.

--
http://www.kartris.com
Free ASP.NET ecommerce, GPL license, responsive interface, unlimited languages and currencies, supports 1,000,000+ SKUs

InstantForum Problem

Hi Flackster,

I hope your very well. Thank you for your post. I'm sincerely sorry to hear of the trouble and will of course do everything I can to assist. Can you please try the following to help me troubleshoot further.

Open your InstantForum web.config file and locate the following section...

<customErrors mode="RemoteOnly" defaultRedirect="ErrorPage.aspx">
<error statusCode="403" redirect="NoAccess.htm"/>
<error statusCode="404" redirect="FileNotFound.htm"/>
</customErrors>


Please change this to...

<customErrors mode="Off" defaultRedirect="ErrorPage.aspx">
<error statusCode="403" redirect="NoAccess.htm"/>
<error statusCode="404" redirect="FileNotFound.htm"/>
</customErrors>


Once you've made this change please create a user account through the registration page. When you click the submit button if a problem is occurring you should see a more detailed error message with a full stack trace. If you could post that exception message here (with sensitive bits removed) or on the ticket I'll certainly assist further. I'm sorry for my delay responding. I'll ensure we assist as quickly as possible with this once we know a litlte more about the error.

I look forward to your response and assisting further,

http://www.instantasp.co.uk/images/line.gif
Kindest Regards,

Ryan Healey



ryan@instantasp.co.uk
www.instantasp.co.uk
Blog | Community | Docs

http://www.instantasp.co.uk/core/assets/images/email/facebook.png http://www.instantasp.co.uk/core/assets/images/email/twitter.png http://www.instantasp.co.uk/core/assets/images/email/google.png http://www.instantasp.co.uk/core/assets/images/email/linkedin.png

Looks like issue was the 'Followers' column in the users table - it didn't accept nulls, so I had to set a default value of ((0)) for it. PM is working for new users, I will try to see if I can fix older ones.


--
http://www.kartris.com
Free ASP.NET ecommerce, GPL license, responsive interface, unlimited languages and currencies, supports 1,000,000+ SKUs


I added in an instantForum users record for one of the new registrants where this was missing. The PM page does now find the user in the lookup, but when I send mail, it gives this error:

---
The recipient you specified does not exist. Please ensure you entered the username correctly.
---

So I think there are other records that need to be created for each user immediately after the one in instantforum_users.

Could you indicate which other records are created for a new user (or better still, is there some SQL code that could do this)? That way I can try to fix the hundred or so users I have that are missing these records.

thanks

--
http://www.kartris.com
Free ASP.NET ecommerce, GPL license, responsive interface, unlimited languages and currencies, supports 1,000,000+ SKUs


Thanks for taking the time to share your findings flackstar. I published an article yesterday to help customers upgrading from 4.1.4. This explains why these default values are lost moving from 4.1.4 to 2010. It's mainly due to the fact we didn't provide a fixed name for these constraints in 4.1.4 or earlier so SQL server assigned a random name. Of course we fixed this with 2010 so it should not happen again. .

You can see the TSQL script needed to add new users here...
https://community.instantasp.co.uk/FindPost17049.aspx

Each new user in InstantForum will need an entry in each of the following tables...

InstantASP_Users <-- core user information (username, email, password etc)
InstantASP_UsersRoles <-- one to many relationship contains roles for user from InstantASP_Roles
InstantForum_Users <-- forum specific user settings (total posts, receive PMs, receive Emails etc)
InstantForum_Folders <-- contains the 3 default private message folders for each user (Inbox, Sent Items, Deleted Items).

I hope this helps you identify any other columns that may be lacking a default value. The majority of our columns don't allow nulls for performance reasons we use a default value. If this default value is missing an error may be thrown when trying to add data to that table.

If I can provide any further information to assist please don't hesitate to respond.

P.S. Your e-commerce platform looks awesome. You should update the URL in your signature to point to your site - it's not a proper hyperlink at the moment :)

http://www.instantasp.co.uk/images/line.gif
Kindest Regards,

Ryan Healey



ryan@instantasp.co.uk
www.instantasp.co.uk
Blog | Community | Docs

http://www.instantasp.co.uk/core/assets/images/email/facebook.png http://www.instantasp.co.uk/core/assets/images/email/twitter.png http://www.instantasp.co.uk/core/assets/images/email/google.png http://www.instantasp.co.uk/core/assets/images/email/linkedin.png

Ok, I think this is all working now. I edited the SQL down as I already had records in InstantASP_Users, but was missing the PM folders and the InstantForum_Users records.

DECLARE @intUserID as Int
SET @intUserID = 999

-- add InstantForum.NET user data
INSERT INTO InstantForum_Users (UserID, PermissionID) VALUES (@intUserID, 0)

-- add required private message folders
INSERT INTO  InstantForum_Folders (UserID,FolderName,InBox,SentItems,DeletedItems,Unread,Total,SortOrder,Required) VALUES (@intUserID, 'PMFolder_DeletedItems',0,0,1,'0','0','1',1)
INSERT INTO  InstantForum_Folders (UserID,FolderName,InBox,SentItems,DeletedItems,Unread,Total,SortOrder,Required) VALUES (@intUserID, 'PMFolder_SentItems',0,1,0,'0','0','2',1)
INSERT INTO  InstantForum_Folders (UserID,FolderName,InBox,SentItems,DeletedItems,Unread,Total,SortOrder,Required) VALUES (@intUserID, 'PMFolder_InBox',1,0,0,'0','0','3',1)


Where 999 is the user ID I need to create the extra records for.

Since only around 100, i just changed number manually and executed - took me less than 5 mins, but it could be scripted if more I guess.

Thanks for your help Ryan, hopefully our forum is back at 100% now.


--
http://www.kartris.com
Free ASP.NET ecommerce, GPL license, responsive interface, unlimited languages and currencies, supports 1,000,000+ SKUs


My pleasure Flackstar. I'm pleased to hear this is working now. Thanks for working with me to resolve this.

To help others who may have similar problems I've included some helpful TSQL script below.

This will loop through your InstantASP_Users table and add private message folders for any accounts missing the required default folders

This will loop through your InstantASP_Users table and add private message folders for any accounts missing the required folders

This will loop through your InstantASP_Users table and add private message folders for any accounts missing the required folders

DECLARE @intUserID int

DECLARE @intEmialAddress nvarchar(255)

DECLARE MSGCURSOR CURSOR FOR

SELECT UserID, EmailAddress FROM InstantASP_Users

OPEN MSGCURSOR

FETCH NEXT FROM MSGCURSOR INTO @intUserID, @intEmialAddress

WHILE @@fetch_status=0 BEGIN

IF NOT EXISTs(SELECT UserID FROM InstantForum_Folders WHERE (UserID = @intUserID))

BEGIN

INSERT INTO InstantForum_Folders (UserID,FolderName,InBox,SentItems,DeletedItems,Unread,Total,SortOrder,Required) VALUES(@intUserID, 'PMFolder_DeletedItems',0,0,1,'0','0','1',1)

INSERT INTO InstantForum_Folders (UserID,FolderName,InBox,SentItems,DeletedItems,Unread,Total,SortOrder,Required) VALUES(@intUserID, 'PMFolder_SentItems',0,1,0,'0','0','2',1)

INSERT INTO InstantForum_Folders (UserID,FolderName,InBox,SentItems,DeletedItems,Unread,Total,SortOrder,Required) VALUES(@intUserID, 'PMFolder_InBox',1,0,0,'0','0','3',1)

PRINT 'Account with email ' + @intEmialAddress + ' was missing PM folders - folders have been added.'

END

FETCH NEXT FROM MSGCURSOR INTO @intUserID, @intEmialAddress

END

CLOSE MSGCURSOR

DEALLOCATE MSGCURSOR


I hope this helps. If I can assist further please don't hesitate to respond,

http://www.instantasp.co.uk/images/line.gif
Kindest Regards,

Ryan Healey



ryan@instantasp.co.uk
www.instantasp.co.uk
Blog | Community | Docs

http://www.instantasp.co.uk/core/assets/images/email/facebook.png http://www.instantasp.co.uk/core/assets/images/email/twitter.png http://www.instantasp.co.uk/core/assets/images/email/google.png http://www.instantasp.co.uk/core/assets/images/email/linkedin.png
GO

Login
Existing Account
Email Address:


Password:


Social Logins

Select a Forum....







InstantASP Forums


Search