Question

Photo of Nate Barber

0

Report Name in Merge Document?

Is there a Lava Syntax method to pass a Report Name or DataView Name to a Merge Document so that the source of the information can be displayed?
  • Photo of Nate Barber

    0

    That is certainly a very helpful start, thank you. Still, I don't necessarily know from which report or dataview the merge was called. If I knew the report id ahead of time and could hard code it, I wouldn't need Lava (I would just hard code the report name). How do I query the report ID that was used to initiate/call the document merge?

    • David Stevens

      You could potentially get it from the query string, using the assign command:
      {% assign reportId = PageParameter:'ReportId' %}'


      Other than that you'd have to add a Lava field on the Report itself with that information to pass into the merge document.

  • Photo of David Stevens

    0

    You can get that information with Lava, but you'll need to use a specific entity command to do so.

    Something like this should get you started:

    {% report where:'Id == 1' %}

         {% for report in reportItems %}

             {{ report.Name }}

        {% endfor %}

    {% endreport %}