Haslett, Andrew
andrew.haslett at ilc.gov.au
Fri Apr 23 01:10:35 CDT 2004
http://www.sqlteam.com/item.asp?ItemID=256 http://www.sqlteam.com/item.asp?ItemID=11021 Reversed: http://www.4guysfromrolla.com/webtech/031004-1.shtml Cheers, Andrew -----Original Message----- From: Martin Reid [mailto:mwp.reid at qub.ac.uk] Sent: Thursday, 22 April 2004 5:28 PM To: dba-sqlserver at databaseadvisors.com Subject: [dba-SQLServer] SQL Question Given a one to many relationship is it possible to produce this output using an SP without the use of cursors etc?? INPUT TABLE 1 1000 IT 1000 Databases 1000 VMS 1001 Spreadsheets 1001 GenStat 1002 Aquatic systems 1002 Research INPUT TABLE 2 1000 Smith 1001 Brown 1002 Foster OUTPUT REQUIRED 1000 Smith IT, Databases,VMS 1001 Brown Spreadsheets,GenStat 1002 Foster Aquatic Systems,Research Martin _______________________________________________ dba-SQLServer mailing list dba-SQLServer at databaseadvisors.com http://databaseadvisors.com/mailman/listinfo/dba-sqlserver http://www.databaseadvisors.com IMPORTANT - PLEASE READ ******************** This email and any files transmitted with it are confidential and may contain information protected by law from disclosure. If you have received this message in error, please notify the sender immediately and delete this email from your system. No warranty is given that this email or files, if attached to this email, are free from computer viruses or other defects. They are provided on the basis the user assumes all responsibility for loss, damage or consequence resulting directly or indirectly from their use, whether caused by the negligence of the sender or not.