Copy-pasting partial or full report

Perhaps this is not something that is going to impress you. But I was really impressed when I saw this feature. We will see how to copy a part of report and full report and paste it into another instance.

We often need to copy a part of report or full report from one Report Studio environment or instance, to another. This might be for re-use purpose or for promoting it to the next stage.

Getting ready

We will use the report created in previous recipe for this one.

How to do it...

  1. Open the report in Report Studio. We will call it the Source instance.
  2. Now open another instance of Report Studio from same connection portal for same package [GO Data Warehouse (Query)]. We will call this instance Destination.
  3. Now go to Query Explorerin both the instances.
  4. Right click on Query1 from the Source instance and choose Copy.
    How to do it...

    In the Query Explorer of the Destination instance, right-click and choose to Paste.

  5. You will see that the Query Subject is successfully copied. You can open it and check the data items. They carry all the properties properly.
  6. Now go to Report Page in the Source instance. Select the list object. This time hit Ctrl+C on the keyboard to copy it.
  7. Switch to the Destination instance. Go to Report Page. Select the page body and hit Ctrl+V to paste the list object. Change the Query property of this list to Query1.
    How to do it...
  8. Run the report to test it. You will see that the list report is produced correctly.
  9. Finally, we will see how to copy the whole report. For that, go back to the Source instance.
  10. From the menu, choose Tools | Copy Report to Clipboard.
    How to do it...
  11. In the destination instance, from menu, choose Tools | Open Report from Clipboard.
  12. You will see that the whole report has been copied to the destination instance. Here it is a new report that you can validate and save at an appropriate location.

How it works...

When a part of report is selected and copied (using right click+Copy or Ctrl+C), its XML specification is copied on the clipboard. You can paste it in any XML or Text Editor and examine. At destination instance, you can paste this XML specification and Report Studio properly parses it to create the objects.

When the copied object has some dependency, for example, list is dependant on the Query Subject then dependency object should be copied first. That is why we first copied the Query Subject, and then the list.

This feature is useful as it allows a quick re-use of objects and saves time.

The Copy Report to Clipboard and Open Report from Clipboard options are particularly useful in copying the reports across environments or servers. This comes in handy when the packages are promoted to destination environment and hence this saves the export-import hassles.

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset