Show/Hide Toolbars

TMS Data Modeler Documentation

Navigation: TMS Aurelius Export > Customization Script

Adding Schema Name to Table Attribute

Scroll Prev Top Next More

Data Modeler doesn't hold schema information for each table, but when exporting to TMS Aurelius classes you can use customization script to add the schema name to the table attribute. The following script adds the schema name dbo to the table category:


procedure OnClassGenerated(Args: TClassGeneratedArgs);
  if Args.DBTable.TableName = 'category' then    


For example, originally the class would be generated like this:


  [Id('FCategoryID', TIdGenerator.IdentityOrSequence)]
  TCategories = class


With the following script the Table attribute will be like this:


  [Table('Category', 'dbo')]    
  [Id('FCategoryID', TIdGenerator.IdentityOrSequence)]
  TCategories = class