I am needing some clarification on doing math with dates pulled from MySQL.
The date format in the database is YYY-MM-DD and what I want to do is pull
the date out, then add/subtract 30 days from the date.
I have read through the manual, but for some reason, I'm just not getting
it.
Any help
you can use date-sub in the sql command (see the mysql manual) or use
mktime() function in php
bastien
From: Jess Hunter [EMAIL PROTECTED]
To: php-db@lists.php.net
Subject: [PHP-DB] Pulling Date from MySQL then subtract
Date: Sat, 22 Jan 2005 08:37:56 -0600
I am needing some clarification on
Jess Hunter wrote:
I am needing some clarification on doing math with dates pulled from MySQL.
The date format in the database is YYY-MM-DD and what I want to do is pull
the date out, then add/subtract 30 days from the date.
SELECT yourdatecolumn - INTERVAL 30 DAY FROM yourtable WHERE ...
--
Hi there everyone,
Im trying to select data from 3 tables, Im using the following code:
SELECT * FROM MLS, Cond, Comm ORDER BY Price DESC LIMIT 0, 50
But its not working, I thought this is how it worked but I guess Im wrong.
Its just a basic query, but needs to pull all the info from
Hi,
Is it security safe and possible to use my server to
query another server, outside the local zone, and make
updates to another server using a PHP page from my
server?
I'm just wondering.
So in other words I'd have a DB setup to hold users
domains, db names, db usernames, db passwords etc on
Hi,
Is it security safe and possible to use my server to
query another server, outside the local zone, and make
updates to another server using a PHP page from my
server?
I'm just wondering.
So in other words I'd have a DB setup to hold users
domains, db names, db usernames, db passwords etc on
Why do people set auto responses on a mailing list
like this? It's crazy, imagine all the auto replies
this list would generate. As if I care if a user is
not able to reply because they have gone on holidays
or something. If they don't reply obviously they are
not around or can't answer or
What exactly are you trying to do? If you require data from each table and
that data is linked somehow thur some common field (not required to be the
same field across all three tables) you need to include that
SELECT a.*, b.*,c.* FROM MLS a, Cond b, Comm c where [join crtieria] and
[search
Hi there,
Basically I just need to pull ALL the data from ALL the tables listed in the
same query. It doesn't matter in what order the data is displayed and there
is no relation between the tables.
Chris
What exactly are you trying to do? If you require data from each table and
that data is
Hi there everyone,
Im using the following code to populate cities from a huge database:
select name=fm_city[] id=fm_city[] multiple
option value=0Show All/option
?
$sqla = SELECT DISTINCT(Area) FROM MLS_Listings ORDER BY Area;
$sql_resulta =
Hi all!
I wanted to know the best Random Function for PHP.. But please I don't want
duplications to happen at the same second.. because I receive many customers..
And also how can I add [EMAIL PROTECTED], whic abc is a variable... and
localhost.com is a static text??
So I only request from the
Well, first of all.. your subject line mentions GROUP BY which is a database
function for telling the query what to use when performing aggregate functions
like sum, count, average, etc type functions.
That's really not what you're looking at doing here it sounds like. Sounds
like you just
12 matches
Mail list logo