Integrate Yeastar P-Series PBX System with Microsoft SQL

With the integration between Yeastar P-Series PBX System and Microsoft SQL, inbound calls to PBX will automatically trigger contact lookup in your Microsoft SQL database and display the caller's name if a match is found.

Requirements

Make sure that PBX server meets the following requirements:
  • Plan: Enterprise Plan (EP) or Ultimate Plan (UP)
  • Firmware: Version 37.16.0.70 or later

Step 1. Enable Microsoft SQL integration

  1. Log in to PBX web portal, go to Contacts > Company Contacts.
  2. At the top of the page, click Synchronize Contacts.

  3. Turn on the option Enable Microsoft SQL Integration, then complete the following settings.

    Item Description
    Server Address Enter the address of Microsoft SQL server based on your situation.
    • If Microsoft SQL server runs on the default port 1433, enter the server's IP address or domain name.

      For example, enter 192.168.26.19.

    • If Microsoft SQL server runs on a non-default port, enter the server's IP address/domain name and port.

      For example, enter 192.168.26.19:2233.

    Database Name Enter the name of the database.
    Timeout(s) Set the timeout for the connection to Microsoft SQL server.
    User Enter the username to connect to the database.
    Password Enter the password to connect to the database.
    Auto-match Contact Filter

    Enter a SELECT statement for contact caller ID matching, in the format select ${MAP} from {schema_name}.{table_name} where {condition_to filter_number}.

    Example: select ${MAP} from testpbx.contacts where businumber like CONCAT('%', ${NUMBER}, '%')
    • select ${MAP}: Specify the name of the column in the database that you want to display as the caller ID name.
      Note: ${MAP} will be replaced by the field values corresponding to the PBX field (First Name, Last Name, or both) enabled in the Map section.
    • from testpbx.contacts: The table from which you want to select data, which must include two-part names (schema name and table name) in the format {schema_name}.{table_name}.
    • where businumber like CONCAT('%', ${NUMBER}, '%'): Retrieve the records where businumber contains the value of ${NUMBER} anywhere within it.

Step 2. Map contact fields between Yeastar P-Series PBX System and Microsoft SQL

  1. Scroll down to the Map section.
  2. Map the fields that are required for displaying caller's name.

    1. For Contacts ID, First Name, and Business Number, enter the corresponding column name in Microsoft SQL contacts table.
      Note: In this example, Business Number is mapped because it is used as a number filter. You MUST map the number field based on your situation.

      When an inbound call matches a contact in your database, the contact's first name will be displayed.

    2. Optional: To display contact's last name as well, select the checkbox of Last Name, then enter the corresponding column name in Microsoft SQL field.
  3. If you want to synchronize Microsoft SQL contacts to PBX, enable and map the desired fields.

  4. Click Save.

Result

  • Yeastar P-Series PBX System is connected to your Microsoft SQL server.

  • When an inbound call matches a contact in your database, the caller's name will be displayed.

What to do next

If you want to allow extension users to conveniently call Microsoft SQL contacts from Linkus UC Clients, you need to set up contact synchronization from Microsoft SQL server.

For more information, see Set up Contact Synchronization from Microsoft SQL.