I've got a table with Requests in it and another table with RequestHistory info in it. In the RequestHistory table there is a field called Disposition which hold text data. For each Request there could be none or many RequestHistory entries.
Is there a way to pull back all the data in the Request table and all the Disposition data and have it for 1 record for each Request? Something like this:
Data:
Request
RID Request Date
1 Test 1/1/2000
2 Test 2 2/2/2000
RequestHistory
RHID RID Disposition
1 1 Request Opened.
2 1 Request has been discussed
3 1 Request Closed.
4 2 Request Opened.
5 2 Request Closed.
Desired Output
RID Request Disposition
1 Test Request Opened. Request has been discussed. Request Closed.
2 Test 2 Request Opened. Request Closed.
Any idea as to how I can do this with a stored procedure?
Is there a way to pull back all the data in the Request table and all the Disposition data and have it for 1 record for each Request? Something like this:
Data:
Request
RID Request Date
1 Test 1/1/2000
2 Test 2 2/2/2000
RequestHistory
RHID RID Disposition
1 1 Request Opened.
2 1 Request has been discussed
3 1 Request Closed.
4 2 Request Opened.
5 2 Request Closed.
Desired Output
RID Request Disposition
1 Test Request Opened. Request has been discussed. Request Closed.
2 Test 2 Request Opened. Request Closed.
Any idea as to how I can do this with a stored procedure?