TN 040: How to change the Address length in tItem Table of Dream Report internal database?

TN 040: How to change the Address length in tItem Table of Dream Report internal database?

Dream Report creates an internal logging database with predefined column types and sizes for the tables. One such column is the “Address” column, located in “tItem” table. By default, the “Address” column is created as nvarchar(255); however, tagnames that Dream Report may need to record into the database might be longer than 256 charters. So the question is “How to change the maximum Address length in tItem Table of the Dream Report internal database while keeping all previously recorded tags?

Assuming Dream Report is configured to log to a SQL Server database (in the Project Settings > Database Definition), SQL Server Management Studio will be needed to access the database.  Open Management Studio, connect to the SQL Server Instance where Dream Report is logging the data, and select the project database (typically named <DR_ProjectName>)

Open a new query and type:

ALTER TABLE tItem
ALTER COLUMN Address nvarchar(1024) NOT NULL

SQL_Tbl_screen.jpg

 

Execute the Query.  Once complete, verify that the Address field has been updated to the value highlighted above.

This method is valid for versions 2023 R2 and earlier. Pease contact support@dreamreport.com to check if it is also valid for any newer versions of the product.