Results 1 to 2 of 2

Thread: accounts_cstm table not populating

  1. #1
    hkphooey is offline Sugar Community Member
    Join Date
    Jan 2007
    Posts
    94

    Default accounts_cstm table not populating

    Hi,

    I recently added a Custom field to my Accounts module. A field was created in the accounts_cstm table. However I tried to run some manual SQL UPDATE queries on the database and noticed that the queries were failing.

    I looked in the database and notice that the accounts_cstm table only has 47 entries, whereas the accounts table has some 4000 entries. By contrast the contacts and contacts_cstm tables have the same number of entries -- around 10,000

    I figure something is going wrong here. Am I right in assuming that the accounts and accounts_cstm tables should have the same number of entries?

    If so, how can I fix this? I've tried running Repair Custom fields, but this reports no problems for Accounts.

    My next step would be to try to take a list of accounts.id and dump it into accounts_cstm.id_c Is this advisable? And even if it fixes things, it still probably wouldn't get at the root of the problem.

    Any ideas?

  2. #2
    hkphooey is offline Sugar Community Member
    Join Date
    Jan 2007
    Posts
    94

    Default Re: accounts_cstm table not populating

    I've now tried this on our development server:
    - Dump out a list of account.id
    - Use a bunch of these queries to insert them into accounts_cstm
    INSERT INTO `accounts_cstm`(id_c) VALUES ('f371fc4b-a640-0592-eb13-46077057e37e');
    - Now the two tables have the same number of entries
    - Now my original update queries will work:
    UPDATE `accounts` LEFT JOIN `accounts_cstm` ON id=id_c SET `custom_c` = "900,000" WHERE `name` = "DemoCo";

    This produces the desired effect. However the question still remains -- Why is the acccounts_cstm table not being updated properly. Or is this an incorrect assumption on my part?

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. problemi step 6 di SugarSuite-Full-4.0.1h
    By lucia in forum Italiano
    Replies: 0
    Last Post: 2006-12-27, 08:50 AM
  2. 4.0.1 Installation Problem
    By clawton in forum Help
    Replies: 14
    Last Post: 2006-02-13, 04:17 PM
  3. Fatal error: Max
    By spokes2k4 in forum Help
    Replies: 3
    Last Post: 2006-01-15, 03:50 PM
  4. php 5.0.4 + MySQL 5.0.9
    By sergiogu in forum Help
    Replies: 0
    Last Post: 2005-08-30, 04:38 PM
  5. Empty config.php at the end of install
    By aemadrid in forum Help
    Replies: 2
    Last Post: 2005-08-01, 06:29 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
  •