2022.2

Table Of Contents
l
Adatamappingconfiguration,see"Loadingadatamappingconfiguration"onthefacingpage.A
DataModelandsampledataarepartofadatamappingconfiguration.
l
Adatafile,see"Addingdatafromadatafile"onpage713.
l
Adatabase,see"Addingdatafromadatabase"onpage716.
l
JSONsampledata,see"AddingJSONsampledata"onpage720.
Whenyouopenadatafileoradatabase,theDataModelwillbederivedfromit.Thatis,unlessthere
alreadyisanopendatamappingconfiguration;inthatcase,thecurrentdatamappingconfigurationwill
trytoretrievedatafromthefileordatabase,usingitsownDataModelandextractionlogic.
Afteropeningadatamappingconfiguration,datafileordatabase,theData Modelpaneattheright
handbottomshowsthedatafieldsthatoccurinthedata.
TheValuecolumndisplaysdatafromthefirstrecordinthedatafile.UsetheFirst,Previous,Nextand
Lastbuttonstobrowsethroughtherecords,orusethePageUp,PageDown,HomeandEndkeys.
Notethatwhendataisloadeddirectlyfromafileordatabase,allvaluesarestrings.
Designingatemplatewithoutsampledata
Strictlyspeaking,youdon'tneedsampledatatodesignatemplate;theonlythingyoureallyneedin
ordertoaddvariabledatafieldstoatemplateisaDataModel.
YoucanopenaDataModelwithoutdatabyimportingaDataModelfile,aJSONfileoraConnecttem-
platefilefromwithintheDataModelpane,usingthetop-righticon: .Thefile'sdatamodelstructure
willbedisplayedintheDataModelpane,butthedataisnotincluded.
YoucanalsoaddfieldsandtablesandsetdefaultvaluesforfieldsintheDataModelpane;see
"ChangingtheDataModel"onpage974.ThiswayyoucouldevenbuildaDataModelintheDesigner
fromscratch.
However,withoutsampledatayouwon'tbeabletopreviewthetemplatewithactualdatainthe
Designer.
Tip: Itisn'tpossibletoentervaluesdirectlyintheDataModelpane,butthereisaworkaround:
clicktheJSON Sample DatatoolbarbuttonontheDataModelpane.YouwillseeaJSONstring
thatrepresentsasinglerecordbasedonthecurrentDataModel,withdummyvalues(likeempty
stringsandzeros).EditthatJSONstringandclickOKtoinsertthedataintheDataModel.
Generally,thebestwaytoaccessdataisbycreatingadatamappingconfiguration.Withadata
mappingconfigurationyoucan,amongotherthings:
Page 711