| » Stats |
Members: 103,505
Threads: 85,004
Posts: 1,031,271
Top Poster: Karky (9,546) | | Welcome to our newest member, davecarman999 | |
If you register for free, you will be able to post threads, vote on polls and lots more. If you have problems with the registration or logging in, please contact the administrator.
 | |
09-22-2007, 04:00 PM
|
Simple MySQL query Post #11 | | Registered User
Join Date: Jul 2007
Posts: 0
Rep Power: 0 | Quote:
Originally posted by Rcjuk:
move the equals back one place!
| no diff. still invalid.
|
| |
09-22-2007, 04:04 PM
|
Simple MySQL query Post #12 | | Newb
Join Date: Sep 2007
Posts: 0
Rep Power: 0 |
is the first clause definitely legit? my SQL is a bit shaky but shouldn't you be doing an INNER JOIN somewhere? or does it just join them implicitly?
|
| |
09-22-2007, 04:08 PM
|
Simple MySQL query Post #13 | | Registered User
Join Date: Jul 2007
Posts: 0
Rep Power: 0 |
without the date clause, the query works just fine. i WAS working with an inner join at first, but didn't need it.
just checked on phpMyAdmin - the field is a 10 character INT rather than an actual date/time stamp field in the db: that shouldn't matter should it? i mean it's still a ten digit date that is stored...
|
| |
09-22-2007, 04:16 PM
|
Simple MySQL query Post #14 | | Newb
Join Date: Sep 2007
Posts: 0
Rep Power: 0 |
how do you mean? so 10042007 would be representing 10/04/2007. it could be a bit dodgy because i reckon dates would be internally represented using integers too (and no doubt in a different way).
|
| |
09-22-2007, 04:26 PM
|
Simple MySQL query Post #15 | | Registered User
Join Date: Jul 2007
Posts: 0
Rep Power: 0 |
no, it's a proper mysql datestamp - 1148331647 = june 7th for example.
|
| |
09-22-2007, 04:31 PM
|
Simple MySQL query Post #16 | | Registered User
Join Date: May 2007
Posts: 8
Rep Power: 0 | Quote:
Originally posted by Scatter:
no, it's a proper mysql datestamp - 1148331647 = june 7th for example.
| i thought to process the date you need to put (dd MMM yyyy) so the numbers are seperated properly.
it doesn't recognise 10042007 in VB.net anyway.
|
| |
09-22-2007, 04:38 PM
|
Simple MySQL query Post #17 | | Registered User
Join Date: Jul 2007
Posts: 0
Rep Power: 0 |
when i call the data from the db, not trying to use 14 day clause, but using the rest of the query in my first post, and then in my php document put this:
<pre class="ip-ubbcode-code-pre"><p>Posted by <a href="http://forums.thequadrant.org/memberlist.php?mode=viewprofile&u=<?php echo $row_rs_tq_news['news_author']; ?>"><?php echo $row_rs_tq_news['news_author_name']; ?></a> on <?php echo date('l F dS, Y \a\\t h:ia',$row_rs_tq_news['news_datestamp']); ?></p></pre>
i get: Posted by Scatter on Thursday June 07th, 2007 at 07:14am |
| |
09-22-2007, 04:38 PM
|
Simple MySQL query Post #18 | | Registered User
Join Date: Jul 2007
Posts: 0
Rep Power: 0 |
gah. clever |
| |
09-22-2007, 05:01 PM
|
Simple MySQL query Post #19 | | Registered User
Join Date: Jul 2007
Posts: 0
Rep Power: 0 |
got it working - it was the field type in the db. once i changed it to a timestamp it worked...
|
| |  | | | Thread Tools | | | | Display Modes | Linear Mode |
Other threads in forum The Pub | | Thread | Date | Thread Starter | Replies | Last Post | List of manager changes?
List of manager changes?: Hi,
I am looking for a list of all manager...
| 12-01-2007 | Chris Bagnall | 14 | 12-02-2007 08:17 PM | Terminator 4
Terminator 4: so they have found an actor to play the future...
| 11-22-2007 | sunkilmoon | 12 | 11-22-2007 04:32 PM | Later I plan to smoke an entire salmon
Later I plan to smoke an entire salmon: And I'm really not sure how to. Any cigarette or...
| 11-19-2007 | ceefax the cat | 54 | 11-20-2007 05:01 PM | Small I-Net problem. Every website works for me except 1. Please help.
Small I-Net problem. Every website works for me except 1. Please help.: Can't seem to get a website working. I know it...
| 11-14-2007 | lovenkrands01 | 4 | 11-14-2007 10:44 AM | Charlie Jade
Charlie Jade: Never seen a thread but it gets it's UK Premiere...
| 10-26-2007 | Gary Toner | 3 | 10-26-2007 12:59 AM | | » Online Users: 22 | | 0 members and 22 guests | | No Members online | | Most users ever online was 2,128, 07-21-2008 at 08:27 PM. | |