hello, i have a very complex mail delivery problem that i need help with -
the columns are :account number (each account can show up several times),type (single or company),production date,message type (80 or else) and instant message (1,0)
the constraints are:
if instant message=1 then delivery date=production date
if message type=80 then delivery date=production date+10
if type=single then delivery date=production date+24
if type=company then delivery date=production date+14
messages that are not instant are sent on the 5,15,25 of every month
when deliver a message for a certain account number all messages that were produced until that date are sent with that message
i need to figure out the delivert date (i can't figure out how to do loops)
ex of datebase:
account # type prod. date m.type ins.message delivery date????
553 single 01/05/2011 80 0
626 single 03/05/2011 405 1
626 single 04/05/2011 451 0
626 single 11/05/2011 405 1
626 single 11/05/2011 750 0
626 single 11/05/2011 750 0
626 single 18/05/2011 405 1
626 single 25/05/2011 405 1
871 single 11/05/2011 750 0
871 single 31/05/2011 940 1
thank you
Ori
the columns are :account number (each account can show up several times),type (single or company),production date,message type (80 or else) and instant message (1,0)
the constraints are:
if instant message=1 then delivery date=production date
if message type=80 then delivery date=production date+10
if type=single then delivery date=production date+24
if type=company then delivery date=production date+14
messages that are not instant are sent on the 5,15,25 of every month
when deliver a message for a certain account number all messages that were produced until that date are sent with that message
i need to figure out the delivert date (i can't figure out how to do loops)
ex of datebase:
account # type prod. date m.type ins.message delivery date????
553 single 01/05/2011 80 0
626 single 03/05/2011 405 1
626 single 04/05/2011 451 0
626 single 11/05/2011 405 1
626 single 11/05/2011 750 0
626 single 11/05/2011 750 0
626 single 18/05/2011 405 1
626 single 25/05/2011 405 1
871 single 11/05/2011 750 0
871 single 31/05/2011 940 1
thank you
Ori