+ 2

Hi, I wanna know how we can respect the condition of " the same day" on queries in SQL ?

It's the question : choose the people who have been invited for the interview for various posts in the same day !

26th Oct 2021, 12:20 PM
Marzieh NOROUZI
Marzieh NOROUZI - avatar
10 Respuestas
+ 2
Can you describe the table structure please? I think it's necessary to know that before giving any suggestion ...
26th Oct 2021, 12:33 PM
Ipang
+ 2
Use the system date in MM/DD/YYYY format as a filter in the WHERE clause.....
27th Oct 2021, 5:29 PM
Sanjay Kamath
Sanjay Kamath - avatar
+ 1
Table `entretien` does not have a column named no_candidature, why you have "ON candidature.no_candidature = entretien.no_candidature" I'm not sure I understand what you're trying to do with the GROUP BY and HAVING there. I would probably try to check candidature.date_candidature = entretien.date_entretion For the JOIN condition ...
26th Oct 2021, 3:13 PM
Ipang
+ 1
Sorry I forgot to write no_candidature In the entretien table ! I'm gonna try your solution , thank you so much !
26th Oct 2021, 3:42 PM
Marzieh NOROUZI
Marzieh NOROUZI - avatar
+ 1
The group by And having is for another condition ! 😬
26th Oct 2021, 3:43 PM
Marzieh NOROUZI
Marzieh NOROUZI - avatar
+ 1
Okay I wish you best of luck 👍
26th Oct 2021, 3:45 PM
Ipang
+ 1
eid esal. o/p 10 $3000. eid. esal 20. #4000. 10. 3000 30. *7000. 20. 4000 30. 7000. please write query
18th Dec 2021, 9:08 PM
Ram Mohan Reddy
Ram Mohan Reddy - avatar
0
You're right , But it's in french ,i hope that it's ok for you ! These are my two tables that I guess I have to make a JOIN in order to have the result: Table 1 candidature (No_candidature,Date_candidature,No_poste_No_candidat) Table 2 Entretien (no_entretien,date_entretien, durée_entretien)
26th Oct 2021, 1:34 PM
Marzieh NOROUZI
Marzieh NOROUZI - avatar
0
I wrote : Select No_candidat From candidature join entretien on candidature.no_candidature = entretien.no_candidature Group by No_candidat Having count(No_poste) > 1 ;
26th Oct 2021, 1:37 PM
Marzieh NOROUZI
Marzieh NOROUZI - avatar
0
But I don't know how to put the condition of " at the same day " here , how can I limit the various posts in the same day? For example : 3 posts in 26/2/2021
26th Oct 2021, 1:39 PM
Marzieh NOROUZI
Marzieh NOROUZI - avatar