SwyxServer writes CDRs into a table named IpPbxCDR. To create this table, use one of the SQL initialization scripts downloadable at the end of this article, or create it with the same columns using an appropriate database tool.
Using Microsoft SQLServer
To write CDRs into a Microsoft SQLServer database table the connection string has to be the following
Provider=SQLOLEDB[;Data Source=<serverName>];Initial Catalog=<databaseName>[;Integrated
- <servername> is the SQLServer name to connect to. Omit this parameter when using a local SQLServer
- <databasename> is the database on the sqlserver to connect to. If you omit this parameter the default database of the user is used (see below).
- Parameters in square brackets "" are optional. The "|" character defines aalternative parameters.
If you specify
the database will be accessed using windows authentication (recommended). You have to allow local group SwyxWare Administrators or the SwyxServer service account read and write access to the database table IpPbxCDR.
Alternatively you can use legacy SQLServer authentication by specifying a userid and password:
where <UserID> is the SQLServer login to use and <Password> the password. You have to grant read and write access to the IpPbxCDR database table for this login.
- To write CDRs into a Microsoft SQLServer database named "SwyxCallDetails" on a computer named "ALICE" using Windows authentication the connection string is
Provider=SQLOLEDB;Data Source=ALICE;Initial Catalog=SwyxCallDetails;Integrated Security=SSPI
SwyxWare uses the SwyxServer service account to connect to the database in this case.
- To write CDRs into a Microsoft SQLServer database named "SwyxCallDetails" on a computer named "ALICE" using SQLServer login "Bob" with password "1234" the connection string is
Provider=SQLOLEDB;Data Source=ALICE;Initial Catalog=SwyxCallDetails;User ID=Bob;Password=1234
Note: Always use an own database and not the SwyxWare database ippbx.
Using an ODBC data source
To write CDRs into a ODBC datasource the connection string has to be created as following:
Datasources have to be created as System DSN in the Windows ODBC Data Source Administrator (32-bit). This requires that the ODBC driver required for the database is installed.
Starting with SwyxWare 2015 R40.2, the following databases are supported for the writing of CDR entries:
- Microsoft SQL Server
When writing to MySql servers, there seems to be an instability with the currently distibuted ODBC-connector drivers. The ODBC driver crashes, which leads to instabilities of the SwyxWare server service.
Using the older "mysql connector odbc 5.3.13 win32" with the necessary "Visual C++ Redistributable Packages for Visual Studio 2013" fixes the problem.
SwyxServer writes a warning event log entry into the application event log when the specified database cannot be connected and uses the CDR setting configured in SwyxWare Administration.
Use new schema (Update to SwyxWare 2015 R40)
Since SwyxWare 2015 R40 a new column has been added to the database schema. To alter existing databases please use the ALTER script provided below or do the necessary steps manually. The new column links corresponding calls that included the Mobile Extension Manager. To enable the new column, open the Windows Registry by starting regedit.exe and go to the following path:
Create a new DWORD (32-Bit) Value with the name "CDRVersion" and the value 2. After that restart the services.
The following ZIP file contains an SQL statement to adapt an existing MS SQL CDR database to the new scheme of SwyxWare 2015 R40.
- Update existing MS SQL CDR database to new scheme of SwyxWare 2015 R40
The following ZIP file contains an SQL CreateTable script to create the needed table into an MS SQL, MySQL and PostgreSQL database.
- Write Call Details Records into a database (from SwyxWare 2015 R40-2)
The following ZIP file contains an SQL CreateTable script to create the needed table on a MS SQL Server.
- Write Call Details Records into a database (from SwyxWare 2015)
The third-party contact information included in this article is provided to help you find the technical support you need. This contact information is subject to change without notice. Swyx in no way guarantees the accuracy of this third-party contact information nor is responsible for it's content.
Please sign in to leave a comment.