Results 1 to 5 of 5

Thread: Datafetch from other DB

  1. #1
    john.dsouza is offline Senior Member
    Join Date
    Oct 2009
    Posts
    24

    Default Datafetch from other DB

    Dearl All,

    Can you please let me know is this possible in sugar . .

    what I have done?
    I have created one student list module from backend and deplyoed it under student tab.

    (Problem statement )what I have to done?
    I have 2 site one Joomla and Another is Forum, what I want to do is map both joomla and forum users through CRM the idea is if have made some changes in these users it will be refelected in assigned sites

    I can see my module in crm/module/student here I want to let us know how can I connect to another db.

  2. #2
    kuske's Avatar
    kuske is offline Sugar Community Member
    Join Date
    Oct 2007
    Location
    Germany
    Posts
    2,597

    Default Re: Datafetch from other DB

    It is very simple.
    Just make al little include module with some basic access routines to your external database. Include this in your students module and use it for data exchange to the external system.

    Or use some ETL tool (Like Talend) to connect both databases.
    Harald Kuske
    Pre-Sales Engineer Central Europe

    SUGARCRM Deutschland GmbH
    Erika-Mann-Str. 53, 80636 Munich, Germany
    Email: hkuske@sugarcrm.com
    Home: http://www.sugarcrm.com


  3. #3
    john.dsouza is offline Senior Member
    Join Date
    Oct 2009
    Posts
    24

    Default Re: Datafetch from other DB

    Quote Originally Posted by kuske View Post
    It is very simple.
    Just make al little include module with some basic access routines to your external database. Include this in your students module and use it for data exchange to the external system.

    Or use some ETL tool (Like Talend) to connect both databases.
    Dear kuske,

    I really appreciate your help, can you please elaborate a little bit not able to understand what you exact mean

    Thanks John

  4. #4
    john.dsouza is offline Senior Member
    Join Date
    Oct 2009
    Posts
    24

    Default Re: Datafetch from other DB

    anyone faced the above issue?

  5. #5
    kuske's Avatar
    kuske is offline Sugar Community Member
    Join Date
    Oct 2007
    Location
    Germany
    Posts
    2,597

    Default Re: Datafetch from other DB

    3 years ago anyone in this forum posted a very useful file /include/classes/mysql.php which I atach to this post.
    With this file you can open any other mySQL (I hope you have a mySQL Joomla!) database and work on its data.

    The usage is very simple like that:

    include("include/classes/mysql.php");
    $db = new sql_db($hostname,$dbuser,$dbpassword,$dbname);
    $db->sql_query($sql);
    $db->sql_fetchrow($db->query_result)) ...
    Attached Files Attached Files
    Harald Kuske
    Pre-Sales Engineer Central Europe

    SUGARCRM Deutschland GmbH
    Erika-Mann-Str. 53, 80636 Munich, Germany
    Email: hkuske@sugarcrm.com
    Home: http://www.sugarcrm.com


Thread Information

Users Browsing this Thread

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

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
  •