Which SP level you are currently, if you are above SP 10 , I can suggest you can achieve by Input parameter populated by Stored Proc.
can you check the and this document which was discussed recently and the document to generate the FISC data based on variant , may help you.