Skip to main content
ZenHub houses documentation to support you if you’re using Contensis Classic. Contensis Classic includes our WYSIWYG and templating features. If you’re working with a newer version of Contensis, is your go-to place to find anything Contensis-related when building with content types.
The R83 documentation is unmaintained. There is a newer version of Contensis. Click to find out more and download the latest version.

Create a database connection

This tutorial describes how to setup a site database connection. The database connection is required so that searching and listings can be carried on the website. The tutorial assumes that a database with a user log on account has already been created and there is a folder within the system that has the Database content type assigned to it.

To setup a database connection you will need:

  • The host name of the SQL server (this must resolve from all web servers and the CMS server).
  • The name of the database.
  • The username for the database (which must be a database owner, part of the dbowner role).
  • The password for the database.

Create the SQL database

The process of setting up a SQL database is covered in a separate ZenHub article create a blank database.

Create the database connection

  1. Navigate to the folder where the database connection content type is assigned e.g. Site-Elements/Database
  2. Click on the folder and select Create New Content from the context menu, the content creation wizard will open.
  3. Enter a title for the new database connection, e.g. [projectname]-preview in the Title box, the titles for the file and menu names will be created automatically.
  4. Click Finish. The Content Confirmation screen confirms the creation of the new Database connection.
  5. Press Edit New Database on the Content Confirmation screen. The Database Connection Editor screen will open.
  6. Enter the SQL Server name, Database Name, Username and Password details.
  7. Press Test Connection, to confirm a connection can be established. A confirmation dialog will be displayed if the connection is successful.
  8. Click Save, then click the Workflow drop down and select Submit and Approve. You have now created the database connection.

Assign the connection to your publishing server

  1. Click the Cog icon in the top toolbar or below the navigator panel to open up the Management Console.
  2. Click on or expand Project Setup.
  3. Click on Publishing Servers in the Project Explorer or the Publishing Servers tab in the main interface.
  4. If you have already created a publishing server click the Edit icon next to the server. If you don't have a publishing server, Click Create Publishing Server button, the Create new Publishing Server dialog will open.
  5. Select the database connection from the dropdown.
  6. Save the server details.

Setup your search content table

To have dynamic content on your site such as searches and listings you need to have a search content table configured. To do this is straightforward.

  1. Once you have followed the steps above to assign the database connection, re-edit the server and press the Create Search Table button.
  2. Pressing this button will create a table with the name you specified in the Search table name field, by default this is Searchcontent.

In addition to creating a table the system also creates a SQL full-text catalog, this is covered in more detail in how to configure and manage full-text search indexing.