Connecting Tech Pros Worldwide Forums | Help | Site Map

how to make sql query for comparison condition

Newbie
 
Join Date: Feb 2007
Location: malaysia
Posts: 14
#1: Feb 26 '07
hye guest..
anybody can help me how to make sql query for comparison condition.
in case,i want to generate report between range two date for example 1/2/2007 until 20/2/2007?

ronverdonk's Avatar
Moderator
 
Join Date: Jul 2006
Location: The Netherlands
Posts: 4,139
#2: Feb 26 '07

re: how to make sql query for comparison condition


Welcome to The Scripts!

Next time i'll advise you to just read the MySQL manual. You would have found

Expand|Select|Wrap|Line Numbers
  1. SELECT * FROM tab WHERE date BETWEEN '2007-02-01' AND '2007-02-20';
Ronald :cool:
Newbie
 
Join Date: Feb 2007
Location: malaysia
Posts: 14
#3: Feb 27 '07

re: how to make sql query for comparison condition


thank's so much ronverdonk !

actually i develop my database system using mysql phpMyAdmin for my industrial training project.
but, when i use mysql in php environment it's really different with sql right??
there have several different or limitation, for example in php language do not support for nested query.

so,i have problem when make select query from two or more than one table.

this is a new one that i learn in different database language..
Newbie
 
Join Date: Apr 2009
Posts: 1
#4: Apr 22 '09

re: how to make sql query for comparison condition


All right. I will forgive you
Reply