473,387 Members | 1,579 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,387 software developers and data experts.

automatic delete of out of date entries

IIS, Access 2000
I have a page that tabulates data from a DB, this data is items for sale,
private ads.

is there a way that at the same time it can automatically delete entries
that are outside of a specific date..ie. more than a week old??

or should I run two queries seperately..one page which goes through the DB
and deletes out of date entries and then redirects to another page which
then outputs the remaining ones.

I don't really want to have to run an admin script every day to delete the
entries, I would prefer it to be done automatically when the data is
requested. This way the data presented is guaranteed to be up to date as the
deletion is carried out immediately prior to the data being served.

Another question to follow along side this one but under the same sort of
conditions...

I have the ability to upload pictures to these ads, but I have previously
had to do this on a seperate page to that of entering the information for
the ad itself.

What I wish to do is have the picture upload (pureASPupload) and the data
entry to the database carrried out at the same time on the same page.

how would I go about doing this?

how do I get one submit button to both upload the file *and* update the DB
at the same time.

many thanks
Jul 19 '05 #1
4 2735
Alistair wrote:
IIS, Access 2000
I have a page that tabulates data from a DB, this data is items for
sale, private ads.

is there a way that at the same time it can automatically delete
entries that are outside of a specific date..ie. more than a week
old??

or should I run two queries seperately..one page which goes through
the DB and deletes out of date entries and then redirects to another
page which then outputs the remaining ones.
I don't really want to have to run an admin script every day to
delete the entries, I would prefer it to be done automatically when
the data is requested. This way the data presented is guaranteed to
be up to date as the deletion is carried out immediately prior to the
data being served.
Why do they need to be deleted? Why not simply request records that are less
than a week old?

Another question to follow along side this one but under the same
sort of conditions...

I have the ability to upload pictures to these ads, but I have
previously had to do this on a seperate page to that of entering the
information for the ad itself.

What I wish to do is have the picture upload (pureASPupload) and the
data entry to the database carrried out at the same time on the same
page.

how would I go about doing this?

how do I get one submit button to both upload the file *and* update
the DB at the same time.

many thanks


I am not sure about this. I do not think that you can do this, but I've
never tried.
It always helps if you ask one question per post, so people can choose which
wone they want to answer.

Bob Barrows
--
Microsoft MVP - ASP/ASP.NET
Please reply to the newsgroup. This email account is my spam trap so I
don't check it very often. If you must reply off-line, then remove the
"NO SPAM"
Jul 19 '05 #2
1) You can execute two sql statements on your page. The first to delete the
old ads, the second to get the remaining ads. But, as Bob said - do they
have to be removed?
2) I believe ASPUpload has a method of extracting the other form field
values. Yes... here
http://www.aspupload.com/manual_simple.html
under Files and Forms Collection it tells you how and gives an example.

Tom B

"Alistair" <news@*remove*alistairb.co.uk> wrote in message
news:vu************@corp.supernews.com...
IIS, Access 2000
I have a page that tabulates data from a DB, this data is items for sale,
private ads.

is there a way that at the same time it can automatically delete entries
that are outside of a specific date..ie. more than a week old??

or should I run two queries seperately..one page which goes through the DB
and deletes out of date entries and then redirects to another page which
then outputs the remaining ones.

I don't really want to have to run an admin script every day to delete the
entries, I would prefer it to be done automatically when the data is
requested. This way the data presented is guaranteed to be up to date as the deletion is carried out immediately prior to the data being served.

Another question to follow along side this one but under the same sort of
conditions...

I have the ability to upload pictures to these ads, but I have previously
had to do this on a seperate page to that of entering the information for
the ad itself.

What I wish to do is have the picture upload (pureASPupload) and the data
entry to the database carrried out at the same time on the same page.

how would I go about doing this?

how do I get one submit button to both upload the file *and* update the DB
at the same time.

many thanks

Jul 19 '05 #3

"Bob Barrows" <re******@NOyahoo.SPAMcom> wrote in message
news:O3**************@TK2MSFTNGP11.phx.gbl...
Alistair wrote:
IIS, Access 2000
I have a page that tabulates data from a DB, this data is items for
sale, private ads.

is there a way that at the same time it can automatically delete
entries that are outside of a specific date..ie. more than a week
old??

or should I run two queries seperately..one page which goes through
the DB and deletes out of date entries and then redirects to another
page which then outputs the remaining ones.

I don't really want to have to run an admin script every day to
delete the entries, I would prefer it to be done automatically when
the data is requested. This way the data presented is guaranteed to
be up to date as the deletion is carried out immediately prior to the
data being served.


Why do they need to be deleted? Why not simply request records that are

less than a week old?

I just didn't want old records kept in the DB...the ad rate is about 100 per
week and keeping old ones would soon make for a large DB.

Another question to follow along side this one but under the same
sort of conditions...

I have the ability to upload pictures to these ads, but I have
previously had to do this on a seperate page to that of entering the
information for the ad itself.

What I wish to do is have the picture upload (pureASPupload) and the
data entry to the database carrried out at the same time on the same
page.

how would I go about doing this?

how do I get one submit button to both upload the file *and* update
the DB at the same time.

many thanks


I am not sure about this. I do not think that you can do this, but I've
never tried.
It always helps if you ask one question per post, so people can choose

which wone they want to answer.

I have to say I haven't tried it either yet, but I thought I'd ask first, as
it seems on first glance that it might be a bit tricky.

Bob Barrows
--
Microsoft MVP - ASP/ASP.NET
Please reply to the newsgroup. This email account is my spam trap so I
don't check it very often. If you must reply off-line, then remove the
"NO SPAM"

Jul 19 '05 #4
Alistair wrote:
"Bob Barrows" <re******@NOyahoo.SPAMcom> wrote in message
news:O3**************@TK2MSFTNGP11.phx.gbl...
Alistair wrote:
IIS, Access 2000
I have a page that tabulates data from a DB, this data is items for
sale, private ads.

is there a way that at the same time it can automatically delete
entries that are outside of a specific date..ie. more than a week
old??

or should I run two queries seperately..one page which goes through
the DB and deletes out of date entries and then redirects to another
page which then outputs the remaining ones.


I don't really want to have to run an admin script every day to
delete the entries, I would prefer it to be done automatically when
the data is requested. This way the data presented is guaranteed to
be up to date as the deletion is carried out immediately prior to
the data being served.


Why do they need to be deleted? Why not simply request records that
are less than a week old?


I just didn't want old records kept in the DB...the ad rate is about
100 per week and keeping old ones would soon make for a large DB.


?
How much data is in these records? You do realize that a Jet database can
grow to 2GB ...

To answer your question, there is no way to automatically delete records,
other than by scheduling a process that does the deletions.

You do realize that you can run two queries on a single page: one to delete
the old records, and the second to retrieve the new records .... There is no
need to go through this "redirect" process.

Bob Barrows

--
Microsoft MVP - ASP/ASP.NET
Please reply to the newsgroup. This email account is my spam trap so I
don't check it very often. If you must reply off-line, then remove the
"NO SPAM"
Jul 19 '05 #5

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

10
by: nick_faye | last post by:
Hi guys, i'm still a newbie in using MS Access and in VB programming. I am using DAO connection from my VB to access the entries on my MS Access table. I am having trouble in editting and...
4
by: Wilsoch | last post by:
Non-programmer here again because my developer stinks. I'm desperately seeking a solution to this issue: I need something in the open event on my main form that will cause all of the tables to...
1
by: rdemyan via AccessMonster.com | last post by:
My App has 10 or so tables that we provide that contains proprietary data. This data will need to be updated once or twice a year. I would like some comments, suggestions on my proposed strategy...
2
by: stan | last post by:
I'm sure I'm missing something simple here; help will be appreciated. I've got a search form that displays records from a MySQL db matching criteria entered by the user; the search form appears...
1
by: klimmass | last post by:
Hello Does anybody know a tool/macro with can automatically add a header comment to a .cs file at saving it ? I want something like this: eg. ///Automatic comment //CREATED BY: klimmass...
29
by: Jon Slaughter | last post by:
Is it safe to remove elements from an array that foreach is working on? (normally this is not the case but not sure in php) If so is there an efficient way to handle it? (I could add the indexes to...
4
by: ramdil | last post by:
Hi All I have table and it have around 90000 records.Its primary key is autonumber field and it has also have date column and name, then some other columns Now i have problem with the table,as my...
3
allingame
by: allingame | last post by:
Need help with append and delete duplicates I have tables namely 1)emp, 2)time and 3)payroll TABLE emp ssn text U]PK name text
1
by: priyammaheshwari | last post by:
Hi All I am creating a database archiving tool,in which a user can delete all the data before a date he would specify.But the problem is i am not able to create a delete query which can delete a...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.