March 28, 2011 at 4:05 am
Hi all,
I have a delivery report (Crystal Reports XI) which I want to get printed out twice. And the second time should have a watermark "COPY" on it. Since I am not a fan of subreports in Crystal, I want to solve this in TSQL. So I have to double the resultset and add a new column (0=original / 1=copy).
What's the best (performance) way to do this?
1. Use a cartesian join?
It's a bit of a pain. I would have to save my resultset (60 fields) in a temp. table because you can't mix a cartesian join with other joins (I think).
2. Create a view?
I could create a view, which executes the report stored procedure twice.
3. Create a stored procedure?
Same as point 2. but instead of a view I create a stored procedure with 'subprocedures'.
Has anyone done this before?
What might be the best way?
Thanks for any help.
Reto E.
March 28, 2011 at 9:08 am
Maybe UNION ALL the two sets and include a column to specify which of the sets is the copy?
Viewing 2 posts - 1 through 1 (of 1 total)
You must be logged in to reply to this topic. Login to reply