I am looking for a script I can run that will take a large output table and split it into several smaller tables of approximately equal size. The large table is an order detail table used to generate an email notice to customers. The customers can not span multiple tables as I only want to send one email per customer. I attach the tables to a 3rd party app that generates the email message.
I have no idea where to start on this and need some direction.
Any ideas and code examples are appreciated.
For help on getting help, follow the link below:http://www.sqlservercentral.com/articles/Best+Practices/61537/