Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chriss Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Query dilemma

Status
Not open for further replies.
Joined
Jul 24, 2000
Messages
11
Location
US
Hello!<br>I am trying to write an SQL statement that looks at an individual 'request' and then checks the audit trail to see if the issue has been reopened.&nbsp;&nbsp;If the issue has been reopened, assign the issue a &quot;1&quot;, else assign it a &quot;0&quot;<br>the final table would look like this.&nbsp;&nbsp;There is a separate request table and a separate audit table with multiple audit codes<br><br>requestid : timecreated : audit(reopen)<br><br>2006&nbsp;&nbsp;&nbsp;01/01/00&nbsp;&nbsp;&nbsp;1<br>2007&nbsp;&nbsp;&nbsp;04/07/00&nbsp;&nbsp;&nbsp;0<br><br>Thanks,<br><br>Oren<br>
 
Oren,<br><br>Do you have the requestid column in the audit trail? <p>Mike<br><a href=mailto:michael.j.lacey@ntlworld.com>michael.j.lacey@ntlworld.com</a><br><a href= Cargill's Corporate Web Site</a><br>
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top