Previous Thread
Next Thread
Print Thread
Rate Thread
#278517 08/25/2004 7:06 PM
Joined: Sep 2003
Posts: 488
Code Monkey
Code Monkey
Joined: Sep 2003
Posts: 488
I'm attempting to do a mod which selects all replies to your posts only, BUT ONLY if you haven't yet replied to those replies.

I have the first section down no prob (ie. all replies to your posts)...

Code
// ----------------------------------<br />// Give all the replies for this user<br />	$query = "<br />         SELECT t1.B_Number,t1.B_Subject,t1.B_PosterId,t1.B_Board,t1.B_Posted,t2.U_Number,t2.U_Username,t3.Bo_Title<br />         FROM  {$config['tbprefix']}Posts as t1,<br />               {$config['tbprefix']}Users as t2,<br />               {$config['tbprefix']}Boards as t3<br />	     WHERE t2.U_Number <> {$user['U_Number']}<br />         AND t1.B_Main <> 0<br />         AND t1.B_ParentUser = {$user['U_Number']}<br />         AND t3.Bo_Keyword = t1.B_Board<br />         AND t1.B_PosterId = t2.U_Number<br />         AND t1.B_PosterId <> {$user['U_Number']}<br />         AND t1.B_Approved = 'yes'<br />         AND t1.B_Board <> 'shoutboxpal'<br />         $groupquery<br />         ORDER BY t1.B_Posted Desc<br />   ";<br />   $sth = $dbh -> do_query($query);  


Any idea how to narrow the results for the 2nd part now? This is a li'l dicey

Sponsored Links

Link Copied to Clipboard
Donate Today!
Donate via PayPal

Donate to UBBDev today to help aid in Operational, Server and Script Maintenance, and Development costs.

Please also see our parent organization VNC Web Services if you're in the need of a new UBB.threads Install or Upgrade, Site/Server Migrations, or Security and Coding Services.
Recommended Hosts
We have personally worked with and recommend the following Web Hosts:
Stable Host
bluehost
InterServer
Visit us on Facebook
Member Spotlight
Nettomo
Nettomo
Germany, Bremen
Posts: 417
Joined: November 2001
Forum Statistics
Forums63
Topics37,575
Posts293,930
Members13,823
Most Online6,139
Sep 21st, 2024
Today's Statistics
Currently Online
Topics Created
Posts Made
Users Online
Birthdays
Top Posters
AllenAyres 21,079
JoshPet 10,369
LK 7,394
Lord Dexter 6,708
Gizmo 5,833
Greg Hard 4,625
Top Posters(30 Days)
Top Likes Received
isaac 82
Gizmo 20
Brett 7
WebGuy 2
Morgan 2
Top Likes Received (30 Days)
None yet
The UBB.Developers Network (UBB.Dev/Threads.Dev) is ©2000-2025 VNC Web Services

 
Powered by UBB.threads™ PHP Forum Software 8.0.1
(Snapshot build 20240918)