Page 1 of 2 12 LastLast
Results 1 to 10 of 16

Thread: Export not exporting correct data

  1. #1
    southwestcrm is offline Sugar Community Member
    Join Date
    May 2007
    Posts
    171

    Default Export not exporting correct data

    Sugar OS 4.5.1.d

    1. go to Accounts list
    2. notice a previous search filter has narrowed your list (if you want to test this you will need to set this up)
    3. you want to export every account in the database so
    4. you click Export at bottom of filtered list
    5. you select export "entire list" from the submenu
    6. you then realise that only the filtered list of Accounts is exported.... so
    7. you go back and remove the filter
    8. you are now looking at the 1st page of all accounts in db
    9. you click Export again (Entire list)
    10. the same filtered list of accounts is exported and NOT the entire list

    I can't seem to get the system to forget the last filter....
    Is it me or is it Sugar?

  2. #2
    kbrill's Avatar
    kbrill is offline SugarCRM PS Engineer
    Join Date
    Jul 2004
    Location
    St Louis, MO
    Posts
    3,183

    Default Re: Export not exporting correct data

    No, I would say that is either a bug in 451d (because I just tested it in 451e and it didn't happen) or it's an issue with your browser, maybe a cache issue or something (that select entire list dropdown thing uses AJAX I think so the browser cache might play a role).
    Kenneth Brill - Help Forum Moderator

    I do not respond to 'Private Messages'. Please email me directly instead

    When asking for help, PLEASE give us your Server Information and Version Numbers as asked for on the 'Post New Message' screen as well as any JavaScript errors shown at the bottom of the browser window.
    Help us Help You

  3. #3
    southwestcrm is offline Sugar Community Member
    Join Date
    May 2007
    Posts
    171

    Default Re: Export not exporting correct data

    It seems this issue remains in Version 4.5.1g (Build 1003). However it is definately a cache issue. I deleted my cache and Sugar exported the correct data. I doubt though it is an issue with my system as I have come across this type of issue before with other web-based systems and it is usually (not always!) some kind of programming glitch within the application.

    For now though I have a solution so thanks for the guidance kbrill.

  4. #4
    ukdazza is offline Member
    Join Date
    Nov 2007
    Posts
    6

    Default Re: Export not exporting correct data

    might sound stupid, but how do i clear cache then as it is still not working properly.

    export entire sheet and only 1544 come out into excel and yet it tells me there are 1711 in the database?!

    Please HELP!

  5. #5
    southwestcrm is offline Sugar Community Member
    Join Date
    May 2007
    Posts
    171

    Default Re: Export not exporting correct data

    In Internet Explorer 7 you clear cache via:
    1. Tools menu
    2. Internet Options
    3. General TAB
    4. Delete...
    5. Temporary Internet Files...Delete Files...

    Then try again.

  6. #6
    ukdazza is offline Member
    Join Date
    Nov 2007
    Posts
    6

    Default Re: Export not exporting correct data

    thats what i thought you meant. did and done that several times. restarted comp/restarted internet.

    and yet it is still being totall rubbish. says there are 1711 and only exports 1545...but if i even export the two pages (1-999 & 1000-1711) seperately it only exports 1541...what the hell is it doing?!

    I am starting to think "screw it" just lose some contacts, I am sure they are in my inbox somewhere, any more ideas anyone as I don't really want to lose contacts!

  7. #7
    southwestcrm is offline Sugar Community Member
    Join Date
    May 2007
    Posts
    171

    Default Re: Export not exporting correct data

    [1]
    when you say "but if i even export the two pages (1-999 & 1000-1711) seperately it only exports 1541" do you mean that you export page1 and this exports 999 records then you export page2 and this only exports 542 records? or, is the first export missing some of the 999 records?

    [2]
    With the xls open CTRL+END takes you to which row number?

    [3]
    Are you able to identify one of the contacts that exists in Sugar but does not exist in your xls sheet? Is this contact different to the others in any way?

    [4]
    where exactly in Sugar are you looking to see that there are 1711 records in the database?

    [5]
    Where are you exporting data from? e.g. where in Sugar?

    [6]
    Have you searched the forums for similar issues?

  8. #8
    ukdazza is offline Member
    Join Date
    Nov 2007
    Posts
    6

    Default Re: Export not exporting correct data

    well. it told me there were that many records. i was exporting from the contacts page. i exported page 1 and some were missing and page two and some were missing. identifing which records were missing from the lists was hard, and took a long time of searching....i got bored.

    decided that i had the original datasheet that was near the current total of contacts. i have a few scattered around outlook and other files and i estimated that they about equalled the same total. set the settings to view 1711 on one page, delete all. re-import from new list (created from the contacts lists i found from original upload) and now we have a near 1711 database again lol....stupid thing.

  9. #9
    southwestcrm is offline Sugar Community Member
    Join Date
    May 2007
    Posts
    171

    Default Re: Export not exporting correct data

    What I've noticed in Sugar is that the EXPORT function (on the Contacts Listview) ONLY exports contacts that are linked to an Account. In other words if you create a contact that does not have an Account, the contact won't be included in the exported CSV file.

    Does anyone know an SQL query that can extract contacts where there is no account associated??

    It would be nice if Sugar was able to show me these records but since not I am trying to use Navicat to build an SQL query. I have linked the CONTACTS, ACCOUNT_CONTACTS and ACCOUNTS Tables but not sure how to construct the query to find records where the accounts_contacts.id or accounts.name is null or empty etc.... I can't simply search on the Contacts table because there is no accounts field within it to reference.

    Any SQL skills out there or anyone with a better idea?

  10. #10
    Echoditto is offline Junior Member
    Join Date
    Dec 2007
    Posts
    3

    Default Re: Export not exporting correct data

    Hi there -

    We ran into this same problem. The fix, fortunately, is easy! Its just a bad JOIN.

    In the file modules/Contacts/Contacts.php, change the following SQL query :

    SELECT contacts.*, accounts.name as account_name, users.user_name as assigned_user_name FROM contacts LEFT JOIN users ON contacts.assigned_user_id=users.id LEFT JOIN accounts_contacts ON contacts.id=accounts_contacts.contact_id LEFT JOIN accounts ON accounts_contacts.account_id=accounts.id where ( contacts.deleted=0) AND ( accounts.deleted IS NULL OR accounts.deleted=0 ) AND contacts.deleted=0 AND accounts_contacts.deleted=0

    to

    SELECT contacts.*, accounts.name as account_name, users.user_name as assigned_user_name FROM contacts LEFT JOIN users ON contacts.assigned_user_id=users.id LEFT JOIN accounts_contacts ON contacts.id=accounts_contacts.contact_id LEFT JOIN accounts ON accounts_contacts.account_id=accounts.id where ( contacts.deleted=0) AND ( accounts.deleted IS NULL OR accounts.deleted=0 ) AND contacts.deleted=0 AND (accounts_contacts.deleted=0 OR accounts_contacts.deleted IS NULL)

    And you'll get all your contacts - with and without accounts!

Page 1 of 2 12 LastLast

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. Replies: 0
    Last Post: 2007-09-11, 05:01 PM
  2. Replies: 3
    Last Post: 2007-05-24, 04:15 PM
  3. Exporting / Importing Data
    By mwyres in forum Installation and Upgrade Help
    Replies: 0
    Last Post: 2007-02-18, 11:17 PM
  4. Export data from SugarSuite 3.0?
    By pwalther in forum Help
    Replies: 1
    Last Post: 2007-02-05, 11:28 PM
  5. Replies: 1
    Last Post: 2006-08-03, 10:06 AM

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
  •