You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 2 Next »

Goal

You want to derive part of your model from an external source. For Instance you would like to determine the street name and town based on the postalcode and housenumber. 

Ingredients

  • Entities
  • Attributes
  • CSV Wizard
  • CSV File
  • Data rule
  • Page
  • Flow

Recipe

Use a data rule to derive information for one or more attribute values.

 

The following domain model displays a Person and Address Entity.

We will use the a CSV file that has a list of all available adresses to load the street name and town based on the postalcode and town

StreetHousenumberPostalcodeTown
Veemarktkade85222 AEs-Hertogenbosch
Reitscheweg555232 BXs-Hertogenbosch
Wolvenhoek15211 HHs-Hertogenbosch
Verwersstraat415211 HSs-Hertogenbosch

 

You can use the CSV wizard to create a datarule that uses a CSV datasource

 

  • Select the Connectivity tab
  • Select CSV Wizard
  • Select Data rule
  • Select create new resource
  • Enter a name and select a CSV file
  • Select the format settings

  • Enter the selection criterea and goals



  •  Finish the wizard, a new data rule is created

 

To test your datarule create a page that contains al attributes. Make sure that you add a refresh to the attributes that are used as input (postalcode, housenumber) and ensure that the attributes that are used as goal ( street and town ) are set to read-only.

See also

Example project: CSVDataRule.project.zip

CSV used in the example project: PostalcodeTable.csv

 

  • No labels