A LET expression defines variables var1, var2, … or field symbols
See example below:
- in line 25 and line 26 we define two auxiliary fields date and sep with keyword LET, which are used in LET expressions in line 27.
- in line 27 we define a LET expression by keyword IN
- finally the value of LET expression will be calculated and filled to inline variable isodate defined in line 24. We use CONV string to explicitly specify that inline defined variable isodate has type STRING.
Execution result:
Another example:
Defines three local auxiliary variables, x, y, and z, in a constructor expression to construct the values of a structure. The values of the auxiliary variables are used for the structure components.
Execution result:
要获取更多Jerry的原创文章,请关注公众号"汪子熙":