+1-888-365-2779
Try Now
More in this section

Forums / Deployment / NN_NextVale database error

NN_NextVale database error

15 posts, 0 answered
  1. Michael
    Michael avatar
    31 posts
    Registered:
    07 Sep 2007
    13 Apr 2008
    Link to this post
    I am receiving this error when I try to open my site.  I am using  MySql, and everything installed fine, but when I try to enter my admin area I receive this error:

    MySql.Data.MySqlClient.MySqlException: Procedure or function 'NN_NextValue' cannot be found in database

    Any ideas how to fix this?
  2. Pepi
    Pepi avatar
    981 posts
    Registered:
    08 Dec 2016
    15 Apr 2008
    Link to this post
    Hello Michael,

    Most probably, the database your project is trying to connect to is not upgraded yet. Did you make any changes in the original web.config file that comes with an empty site?

    I would recommend you run the
    startup wizard for the project and set the database connection once again. To achieve this, you should make the following settings in the web.config:

        - Disable Role Provider:  
        <roleManager enabled="false" cacheRolesInCookie="true" defaultProvider="Sitefinity">

        - Disable Cms:
        <cms defaultProvider="Sitefinity" pageExtension=".aspx" disabled="true">

    Do let us know how it goes.

    All the best,
    Pepi
    the Telerik team

    Instantly find answers to your questions at the new Telerik Support Center
  3. Abel Braaksma
    Abel Braaksma avatar
    20 posts
    Registered:
    15 Jul 2009
    14 Mar 2010
    Link to this post
    Using the most recent version Sitefinity Community Edition 3.7 sp1 (testing the free version before buying the standard edition), installed through Web Platform Installer, I find myself having the exact same issue. Following your steps to resolve the issue does not seem to work (note, the cms setting still has disabled set to true when this error occurs).

    I've selected MySQL, a newly created database, and a user that has full access to that database. After clicking Continue in the "Set Database" screen, the attached screen appears (screenshot765), which automatically redirects and then shows the error (screenshot766).

    Any ideas how to resolve this? Is MySQL not supported anymore? Should I expect this error in the paid version as well?
  4. Ivan Dimitrov
    Ivan Dimitrov avatar
    16072 posts
    Registered:
    25 Nov 2016
    14 Mar 2010
    Link to this post
    Hello Abel Braaksma,

    The last official version of Community edition is Sitefinity 3.7 SP2. Anyhow, I suggest that you should create a completely new database and try to install the project once again( should drop your current database, create a new one and try the installation). should drop your current database, create a new one and try the installation. Make sure that you have at least MySQL server version 5.1

    The error you see is caused because one of the stored procedures cannot be found, so it has not been created due to some reasons.

    You may get this error if

    you are trying to install the project on a not empty database
    the user you use does not have need permissions to create store procedures.

    Best wishes,
    Ivan Dimitrov
    the Telerik team

    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items.
  5. Abel Braaksma
    Abel Braaksma avatar
    20 posts
    Registered:
    15 Jul 2009
    14 Mar 2010
    Link to this post
    Thanks for your very quick reply on such an old thread!

    The version of MySQL on that server is 5.1.41. If I look at the file Telerik.Cms.dll then its date stamp is 10 March, 2009, version 3.7.2022.5. I'm unsure whether that's SP1 of SP2, but I am sure that I downloaded it just today.

    I tried your suggestions. I deleted the database and recreated it. I upgraded the rights of the user in case I was overlooking something. Unfortunately, no luck, same error again and again. The database and the site are running, as of now, from the same server to rule out any possible remote access issues. I will try to set it up using SQL Server in case that would matter, but I'm reluctant adding another database server to my array as in this particular environment I'm short of resources. Hence I hoped to (re)use the already available MySQL, which has a light footprint.

    Can I turn on debug logging somehow to see which of the creation-statements go wrong?
  6. Ivan Dimitrov
    Ivan Dimitrov avatar
    16072 posts
    Registered:
    25 Nov 2016
    14 Mar 2010
    Link to this post
    Hello Abel Braaksma,

    You are using Sitefinity 3.7 SP1. The problem is related to the server. I am able to install the project using MySql without any problems.
    Unfortunately it is not possible to use some debugging over our code during installation process. You could observe the stored procedures by using MySQL Administrator and check the MySQL server error log to see if there is any related error.

    Below is the missing store procedure. You could try to create it manually.

    CREATE DEFINER=`root`@`localhost` PROCEDURE `NN_NextValue`(in p_CounterID varchar(60), in p_CacheSize int, out nextvalue bigint)
    begin
    UPDATE `sitefinitytest`.`NN_Counters` SET CounterValue  = CounterValue + p_CacheSize WHERE CounterID = p_CounterID ;
    SELECT CounterValue - p_CacheSize + 1 INTO nextvalue
    FROM `sitefinitytest`.`NN_Counters` WHERE CounterID = p_CounterID;
    END


    Regards,
    Ivan Dimitrov
    the Telerik team

    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items.
  7. Abel Braaksma
    Abel Braaksma avatar
    20 posts
    Registered:
    15 Jul 2009
    14 Mar 2010
    Link to this post
    Thank you for your continuous support. After correcting the quotes (and the db names of course), I created the procedure. Running "show procedure status" clearly shows that the procedure is available after manually creating it and that its properties are equal to several dozen other procedures that have been created by Sitefinity setup.

    I'm about to give up on MySQL support for Sitefinity. It may have to do with me running Windows 2008 in 64 bit and running MySQL in 64 bit. However, with other applications (both ASP.NET and PHP) I don't have any serious trouble.  Not being able to raise the loglevel (if any) of Sitefinity gives me no means to research this further. If you think this issue is not unique, I'm willing to research it further if Sitefinity / Telerik can provide me with a debug build (or at least one that has better tracing).

    All the latest tests I did using the root account, to rule out any issues with access errors.

    Before I totally give up, I'll update to the SP2 version of SF 3.7 and if that fails as well, I may try the 4.0 trial.
  8. Abel Braaksma
    Abel Braaksma avatar
    20 posts
    Registered:
    15 Jul 2009
    15 Mar 2010
    Link to this post
    UPDATE: the error changes to a new error when I force a recompile (changing the web.config). Apparently the error is cached (?).

    Next error is: Table 'sitefinitytestdb.nn_counters' doesn't exist

    this may go on and on. Clearly something dreadfully went wrong during creation of the DB and auxiliary statements.
  9. Abel Braaksma
    Abel Braaksma avatar
    20 posts
    Registered:
    15 Jul 2009
    15 Mar 2010
    Link to this post
    Tried the install of Sitefinity 3.7.2057 (3.7 SP2) MSI, but that errorred out the minute it tried to create the virtual directories. Then I tried to download the installation guide, but unfortunately, the link is dead (http://www.sitefinity.com/downloads/productfiles/hhht/InstallationGuide_3___7.pdf gives a 404). There appeared to be another installation guide, which I am following now. Following these instructions, new problems arise. Nothing works if I choose "Classic .NET App Pool" (empty pages with no content) and disabling "Anonymous" gives access denied errors.

    After numerous tries, I'm now down to the following error (after removing everything, I copied the "empty site" ZIP file). I guess I really broke it this time around:

    There was an error trying to connect to the Database Server:
    Could not load file or assembly 'MySql.Data, Version=5.0.7.0, Culture=neutral, PublicKeyToken=c5687fc88969c44d' or one of its dependencies. The located assembly's manifest definition does not match the assembly reference. (Exception from HRESULT: 0x80131040)


    Sorry, but altogether it's quite messy. I hoped to find a good alternative to DotNetNuke, which has become an overrated bloated moloch of a system. But at least it works out of the box. I heard good things about Sitefinity and I love other Telerik products, but after a day spending on installing this and too limited information on what goes wrong where and why (error logging!) I have to consider it a no-go. Sorry again.
  10. Ivan Dimitrov
    Ivan Dimitrov avatar
    16072 posts
    Registered:
    25 Nov 2016
    15 Mar 2010
    Link to this post
    Hi Abel Braaksma,

    The problems you have are related to the MySQl server configuration and IIS settings. The user you use to create the website does not have needed permissions to create an virtual directory. Most probably the same applies for the stored procedures. I also tried to download the Installation guide directly from your account and the pdf was successfully downloaded.

    "Could not load file or assembly 'MySql.Data, Version=5.0.7.0, Culture=neutral," - this is a bug. The dll that you have in your bin is different version from the required one. I attached the correct version to this post. The problem will be sorted out for Sitefinity SP3 that will be released withing a day or two.

    Kind regards,
    Ivan Dimitrov
    the Telerik team

    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items.
  11. Abel Braaksma
    Abel Braaksma avatar
    20 posts
    Registered:
    15 Jul 2009
    15 Mar 2010
    Link to this post
    Yesterday late night I tried again and followed the online guide, leaving out the bits that were too illogical to be part of the problem. The SP2 version works now, but only with SQLExpress (yippee!). I was logged in as admin, but remotely, I guess that was causing some of the trouble during the installation. The PDF still doesn't work for me. I found another online PDF manual after following this link (it contains incorrect pdf links going to 404 pages, apparently you remove the guide when a new version arrives, changing the version nr solved the issue. Suggestion: don't remove old guides or instead, inform the user where to find the update).

    An important thing to note that's neither in the PDF nor in the online guide: out of the box the CMS will not work on 64 bit Windows Server installations! In the settings for application pool, change "Enable 32-Bit Applications" to "True". See screenshot for all non-default settings in bold. I guess some DLLs have been explicitly compiled for 32 bit and a specific 64 bit compilation is needed to enable true 64 bit running.

    Another important thing to note: you do not need to use "Classic .NET AppPool". You can create your own application pool with the same settings as the Classic .NET AppPool. This has the advantage that existing installations, needing the classic pool, won't break.

    About MySQL: I will try that once more, this time with the correct DLL. Apparently, it was correct in SP1, but not in SP2 anymore.
  12. Abel Braaksma
    Abel Braaksma avatar
    20 posts
    Registered:
    15 Jul 2009
    15 Mar 2010
    Link to this post
    Don't bother too much about fixing the MySQL lib so quickly. The same error remains (the NN_NextValue missing error) and it is clearly not a rights-issue: many procedures get created, just not all of them (and just to be sure, all tests are done as admin or root).

    I gladly help analyzing and fixing this (being a long-term developer with many year ASP.NET experience myself) but as said earlier, I either need a debug version (including the PDB's at least) or a version that has logging enabled (what do you use, log4net?).

    Is there possibly a discrepancy in the versions? MySQL dll version 5.0.x for a 5.1.x MySQL installation?
  13. Ivan Dimitrov
    Ivan Dimitrov avatar
    16072 posts
    Registered:
    25 Nov 2016
    15 Mar 2010
    Link to this post
    Hello Abel Braaksma,

     I am sending you a sample video that illustrates installation under MySQL server. The problem is somewhere at your end.

    Greetings,
    Ivan Dimitrov
    the Telerik team

    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items.
  14. Abel Braaksma
    Abel Braaksma avatar
    20 posts
    Registered:
    15 Jul 2009
    15 Mar 2010
    Link to this post
    Thanks for the video. Up and including giving the details for the connection, we are doing the exact same thing. Then comes the error, just before you show the screen about "Register Administrator".

    If I can't somehow turn on tracing, there's little I or you can do at this stage, considering it's probably specific to my situation, or specific to Windows Server 2008 SP2, or specific to my MySQL version 5.1.41 for WIn64 . Would tracing / logging / debug be available in the standard edition?
  15. Georgi
    Georgi avatar
    3583 posts
    Registered:
    28 Oct 2016
    18 Mar 2010
    Link to this post
    Hi Abel Braaksma,

    Would tracing / logging / debug be available in the standard edition?

    Yes, these should be available in standard edition. 
    We are not able to set such environment at the moment though, to test the same scenario. I will check if we can do it though. 

    All the best,
    Georgi
    the Telerik team

    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items.
Register for webinar
15 posts, 0 answered