Please start any new threads on our new
site at https://forums.sqlteam.com. We've got lots of great SQL Server
experts to answer whatever question you can come up with.
| Author |
Topic |
|
adam_bris
Starting Member
2 Posts |
Posted - 2008-06-25 : 20:25:31
|
| HiI have two tables linked by CallID with a one (Call) to many (Assignments) relationship.I would like to create a User Defined Funct. to display all the assignments of a call in one string, separated by carriage retn.For example, if CallID 12345 has assignments A and B, I would like to have them return as:ABThe purpose of this is to have them displayed in a report.I have absolutely no idea if this is possible or how to go about it. Thankyou very much to anyone that can assist. |
|
|
khtan
In (Som, Ni, Yak)
17689 Posts |
Posted - 2008-06-25 : 21:49:03
|
[code]select a.assignmentfrom assignments_table awhere a.CallID = 12345[/code] KH[spoiler]Time is always against us[/spoiler] |
 |
|
|
adam_bris
Starting Member
2 Posts |
Posted - 2008-06-25 : 22:11:07
|
| Thanks khtan,If I was to then report on that however, it would only return the first assignment.I would like to return all assignments in one string, separated by carriage return.Adam |
 |
|
|
khtan
In (Som, Ni, Yak)
17689 Posts |
|
|
|
|
|