Forums

This topic is locked

Retrieving info from db in the coming 5 days?

Posted 09 Oct 2003 13:36:36
1
has voted
09 Oct 2003 13:36:36 Henrik Sandeberg posted:
I have an db (Access) with some fields and one date field called datumet, iwant to get the coming 5 days in the database

I have tested the command:

<pre id=code><font face=courier size=2 id=code> SELECT * FROM sports
WHERE datumet &gt;=DateAdd("d",+5,Date())</font id=code></pre id=code>

I have tried setting the d in quotes and without, but im always getting: Too few parameters, expecting 1

What to do?

Help please....

Henrik

Replies

Replied 09 Oct 2003 19:00:33
09 Oct 2003 19:00:33 Jeremy Conn replied:
Try this...

SELECT * FROM sports WHERE datumet &gt;= Date() AND datumet &lt;= Date() + 5

That should work for you.

<b>Connman21</b>
www.conncreativemedia.com
<b>DEVELOPMENT SETUP</b>
DW MX Studio
Web Server: IIS5
DB: Access2000/SQL2000
OS: XP Pro
Language: ASP/VB

Edited by - connman21 on 09 Oct 2003 19:01:26
Replied 15 Oct 2003 18:42:10
15 Oct 2003 18:42:10 Jeremy Conn replied:
Did this work for you?

<b>Connman21</b>
www.conncreativemedia.com
<b>DEVELOPMENT SETUP</b>
DW MX Studio
Web Server: IIS5
DB: Access2000/SQL2000
OS: XP Pro
Language: ASP/VB
Replied 16 Oct 2003 10:17:11
16 Oct 2003 10:17:11 Henrik Sandeberg replied:
Yes, I have tested that. and that works for me.

/Henrik

Reply to this topic