Results 1 to 5 of 5

Thread: MySQL error 1062 relating to Case Module.

  1. #1
    rbaird is offline Junior Member
    Join Date
    Sep 2009
    Posts
    4

    Default MySQL error 1062 relating to Case Module.

    Hello,

    I have recently deployed Version 5.5.1RC onto a Windows Server 2003 R2 using the WIndows MySQL faststack install.

    The current version through the admin tool is Version 5.5.1RC (Build 1141).

    I have been trying to setup the inbound email to so that I can work on getting case module to auto generate case numbers and emails for our support desk.

    After following all the steps in the manual, I manually created 2 cases in the cases module to test outbound email notification which worked fine.

    I deleted the 2 test cases on purpose, since the deletion, I have been trying to get the inbound email to case auto generation working, I need to setup the cron job on the windows server of which I am still learning how this is done.

    Since the deletion of the old 2 test cases, I have been trying to manually create more test cases, I end up getting the following:

    (indication in my work email

    Administrator has assigned a Case to Richard Baird.

    Subject: TEST EMAIL
    Priority: High
    Status: New
    Description: test

    You may review this Case at:
    <http://10.2.3.47/sugarcrm/index.php?module=Cases&action=DetailView&record=b1 5e45b7-37ba-4a7c-a332-4b85e1e1841c>

    I have tried this a few times and get the following MySQL error for each case I try to manually create.

    Query Failed:INSERT into cases set id='544a745b-8d26-a5bb-f8a3-4b85ee9baed5', name='I need some help here', date_entered='2010-02-25 03:30:26', date_modified='2010-02-25 03:30:26', modified_user_id='90ac8902-d655-a4fc-abf8-4b1483d75000', created_by='90ac8902-d655-a4fc-abf8-4b1483d75000', description='Test', deleted='0', assigned_user_id='90ac8902-d655-a4fc-abf8-4b1483d75000', type='Administration', status='New', priority='P1', resolution='Test', account_id='5829551c-517b-d53f-8942-4b0f5b860165'::MySQL error 1062: Duplicate entry '0' for key 2

    From reading a lot of posts I believe that there maybe a duplication in the Cases table with regards to the auto increment section??

    I have ensured that the case macro retains the [CASE:%1] as per the note in the web gui.

    I need to provide my IT department instructions to rectify this issue, can annoy help as to how I can fix this MySQL error?

    Kind Regards,

    Richard Baird
    Service Delivery Manager
    rbaird@vexpress.com.au

  2. #2
    Angel's Avatar
    Angel is offline Sugar Community Member
    Join Date
    Jul 2005
    Location
    Los Angeles
    Posts
    4,813

    Default Re: MySQL error 1062 relating to Case Module.

    Unless I've misinterpreted your comments, it sounds like you don't have anything in the Cases module that you actually need to keep.

    Assuming my interpretation is correct, try truncating the cases table to correct the problem.

    You can truncate it by running the following command via a MySQL admin utilty:

    TRUNCATE TABLE cases
    Regards,

    Angel Magaņa
    Co-Author: Implementing SugarCRM 5.x (Packt Publishing -- Sept. 2010)
    Blog: http://cheleguanaco.blogspot.com.
    Twitter: @cheleguanaco.

    ________
    | Projects: |_____________________________________
    |
    | CandyWrapper (.NET Wrapper for SugarCRM SOAP API). Source now available on GitHub!
    | GoldMine to SugarCRM Express Conversion. Latest: 1.0.1.7 (Nov. 3, 2009)
    | CRM SkyDialer (Skype Integration). Latest: 1.0.2 (Feb. 17, 2010)
    | Round Robin Leads Assignment
    | Phone Number Formatter
    | CaseTwit (Twitter Integration)
    ______________________________________________

  3. #3
    monofia is offline Junior Member
    Join Date
    Apr 2010
    Posts
    3

    Default Re: MySQL error 1062 relating to Case Module.

    Quote Originally Posted by Angel View Post
    Unless I've misinterpreted your comments, it sounds like you don't have anything in the Cases module that you actually need to keep.

    Assuming my interpretation is correct, try truncating the cases table to correct the problem.

    You can truncate it by running the following command via a MySQL admin utilty:

    TRUNCATE TABLE cases
    i have the same problem, i keep trying ths, it does not work, is there any solution?

    ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

    Query Failed:INSERT into cases set id='6ec1ed71-9173-62c0-f062-4bd5d98b17b1', name='dhlkjs dsd s', date_entered='2010-04-26 18:21:15', date_modified='2010-04-26 18:21:15', modified_user_id='4a8de105-8a0d-32a0-3490-4bd56148415b', created_by='4a8de105-8a0d-32a0-3490-4bd56148415b', description='sdjf dfdsfkjdf', deleted='0', assigned_user_id='150c6a5f-d01d-6522-9537-4bd56355d0ba', type='Administration', status='New', priority='P1', resolution='dsjkfh skdfh', account_id='9cd88208-af19-1620-1d2a-4bd56e009cc9'::MySQL error 1062: Duplicate entry '0' for key 2
    -----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
    Last edited by monofia; 2010-04-26 at 06:38 PM. Reason: to complete the case

  4. #4
    Angel's Avatar
    Angel is offline Sugar Community Member
    Join Date
    Jul 2005
    Location
    Los Angeles
    Posts
    4,813

    Default Re: MySQL error 1062 relating to Case Module.

    I don't know of any circumstance where this type of error would come up for erroneous reasons, although I do find it odd that it is trying to use 0 as the case number as it usually starts at 1. Did you reset the numbering at some point?
    Regards,

    Angel Magaņa
    Co-Author: Implementing SugarCRM 5.x (Packt Publishing -- Sept. 2010)
    Blog: http://cheleguanaco.blogspot.com.
    Twitter: @cheleguanaco.

    ________
    | Projects: |_____________________________________
    |
    | CandyWrapper (.NET Wrapper for SugarCRM SOAP API). Source now available on GitHub!
    | GoldMine to SugarCRM Express Conversion. Latest: 1.0.1.7 (Nov. 3, 2009)
    | CRM SkyDialer (Skype Integration). Latest: 1.0.2 (Feb. 17, 2010)
    | Round Robin Leads Assignment
    | Phone Number Formatter
    | CaseTwit (Twitter Integration)
    ______________________________________________

  5. #5
    monofia is offline Junior Member
    Join Date
    Apr 2010
    Posts
    3

    Default Re: MySQL error 1062 relating to Case Module.

    Quote Originally Posted by Angel View Post
    I don't know of any circumstance where this type of error would come up for erroneous reasons, although I do find it odd that it is trying to use 0 as the case number as it usually starts at 1. Did you reset the numbering at some point?
    No i did not reset numbering, we just installed it new, and this is the frist case we try to open.

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Meetings SQL Error 1062
    By ptemplin7 in forum Help
    Replies: 2
    Last Post: 2009-12-05, 06:16 PM
  2. How to retreive field value from relating module?
    By ivit in forum Developer Help
    Replies: 9
    Last Post: 2009-02-24, 10:09 AM
  3. Relating data from one module to another
    By jonnywatson in forum Help
    Replies: 1
    Last Post: 2008-08-01, 07:08 AM
  4. MySQL Error 1062 on creation of record
    By monsta in forum Help
    Replies: 9
    Last Post: 2007-10-01, 08:50 AM
  5. Mysql error 1062 on sending campaigns
    By emaggi in forum Help
    Replies: 0
    Last Post: 2006-11-29, 04:15 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •