Menu

select()

Updated: 2025-06-25

Use select() to select a specific row of a table based on data in one of the cells. 

When writing a condition with this function, using a # (number sign) will check so see whether the line number appears. Whereas, using a ^ (caret) will check for the absence of the number.

For example, to display details from specified lines on the T1-ADJ:

  1. This select() statement looks in the Adjustment details section of the T1-ADJ and finds line 43500.
  2. This select() statement looks in the Adjustment details section of the T1-ADJ and only displays the text if it does not find a line 43500.
  3. Once you have selected the line, you can access the details in the other columns of that line and use them to create other conditions or calculations. For example, Previous Amount and Revised Amount columns.

Screen Capture: Template code with the select function

Screen Capture: Line 45300 on the T1-ADJ

Sample Code

{{#CurrentClient}}
{{#Adjustments}}
{{#T1ADJ}}
{{#select(AdjustmentDetails, where(LineNumber = 43500))}}
{{#(PreviousAmount - RevisedAmount)>0}}Overall, this adjustment has decreased your income taxes by ${{format(PreviousAmount - RevisedAmount)}}.{{/end}}
{{#(PreviousAmount - RevisedAmount)<0}}Overall, this adjustment has increased your income taxes by ${{format(abs(PreviousAmount - RevisedAmount))}}.{{/end}}
{{#(PreviousAmount - RevisedAmount)=0}}We have filed an adjustment to your tax return. However, there is no change to your taxes.{{/end}}
{{/end}}
{{^select(AdjustmentDetails, where(LineNumber = 43500))}}We have filed an adjustment to your tax return. However, there is no change to your taxes.{{/end}}
{{/T1ADJ}}
{{/Adjustments}}
{{/CurrentClient}}