Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 673387
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 14, 20262026-05-14T00:35:25+00:00 2026-05-14T00:35:25+00:00

SELECT S.CLIENT,S.IP_DOMAIN as IP, IFNULL(K.DATE, DATE ‘0000-00-00’) AS RecentDate FROM PLD_SERVERS AS S JOIN

  • 0
SELECT S.CLIENT,S.IP_DOMAIN as IP, IFNULL(K.DATE, DATE '0000-00-00') AS RecentDate
      FROM PLD_SERVERS AS S JOIN PLD_SEARCHES AS K ON S.ID = K.SERVER_ID

This query will produce as many results as entries in the PLD_SEARCHES. For example:

I have 3 entries in PLD_SERVERS and 18 entries in PLD_SEARCHES. The output of this query will be 18 but i need it to be 3 (as the number of PLD_SERVERS entries) with the recent date as a join field from PLD_SEARCHES.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-14T00:35:25+00:00Added an answer on May 14, 2026 at 12:35 am

    How about something like:

    SELECT S.CLIENT,S.IP_DOMAIN as IP
        , IFNULL(
            (
            Select Max(K2.DATE)
            From PLD_SEARCHES AS K1 
            Where S.ID = K1.SERVER_ID
            ), DATE, '0000-00-00') AS RecentDate
    FROM PLD_SERVERS AS S 
    Where Exists(   
                Select 1
                From PLD_SEARCHES AS K1 
                Where S.ID = K1.SERVER_ID
                )
    

    Here I’m using the Exists function to determine which rows to show and then I use a second subquery to find the last date.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have this php code $jsonArray = array(); $sql = SELECT ID,CLIENT FROM PLD_SERVERS;
I've done this :- $qry=mysql_query(SELECT client.resID, menu.name FROM client INNER JOIN menu ON client.resID
With regards to the following statement: SELECT * FROM explorer.booking_record booking_record_ INNER JOIN explorer.client
I'm developing an ASP.NET form for data-entry. Users have to select a client from
I have this ajax call executing from client side, with jQuery, but at times,
My goal is simple: JOIN by IP addresses from different logs; at the client-side
Hi anybody know how to select and read client page data using c# and
I'm writing a select query in a C# method which lets client code provide
My client wants, when customer loges in, he should be prompted to select a
Client code is pretty simple: <form action=DDServlet method=post> <input type=text name=customerText> <select id=customer> <option

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.