Jan 24, 2007 #1 wangyc77 Programmer Jan 24, 2007 1 TW I would like to make the following data in my database SID fromDate ToDate Price 1 2006/01/01 2006/1/3 100 1 2006/1/4 2006/1/5 150 into SID Adate Price 1 2006/1/2 100 1 2006/1/3 100 1 2006/1/4 150 When I specify a range Please help~~!!
I would like to make the following data in my database SID fromDate ToDate Price 1 2006/01/01 2006/1/3 100 1 2006/1/4 2006/1/5 150 into SID Adate Price 1 2006/1/2 100 1 2006/1/3 100 1 2006/1/4 150 When I specify a range Please help~~!!
Jan 24, 2007 #2 r937 Technical User Jun 30, 2002 8,847 CA what happened to 2006/01/01 and 2006/1/5? why did they get dropped? what are you trying to do? r937.com | rudy.ca Upvote 0 Downvote
what happened to 2006/01/01 and 2006/1/5? why did they get dropped? what are you trying to do? r937.com | rudy.ca
Jan 24, 2007 #3 JarlH Programmer Jul 26, 2002 365 SE You'll need calendar help table containing all dates. Then you can do something like SELECT sid, Adate, price FROM calendartable, currenttable WHERE Adate >= fromDate AND Adata <= toDate Upvote 0 Downvote
You'll need calendar help table containing all dates. Then you can do something like SELECT sid, Adate, price FROM calendartable, currenttable WHERE Adate >= fromDate AND Adata <= toDate