Results 1 to 3 of 3
Thread: Sql problem,Help needed
Dec 18, 2004, 04:42 #1
Sql problem,Help needed
I haven't get any suitable answer so i posting it in here.
My problem is I want to search customer name on the respect of customer last name and date(selecting month and year only not date).but in database i have an date field weddate which has actual date.How to write the sql query?
Could you guide me?
I have posting what i have done it:
SELECT * FROM `user_wedding` where blname='$glname' and weddate='$year-$mon-__'
The actual date is not given by user.He given the name of the month and year only. my query would be depend on the name of the month and year.
what is the actuall sql statement?
Dec 18, 2004, 05:00 #2
A SQL question would probably be better suited in the SQL forums .
Dec 18, 2004, 15:41 #3
- Join Date
- Jul 2002
- Toronto, Canada
- 63 Post(s)
- 3 Thread(s)
icheb, this is the sql forum
SELECT * FROM `user_wedding` where blname='$glname' and weddate >= firstofthemonth and weddate < firstdayofnextmonth