PDA

View Full Version : action when subscription expires


glmcps295424
04-14-2009, 06:15 AM
Filtering access to pages by subscriber is working fine.

subscriber table includes expiredate and expired (Y/N) fields.

Can someone suggest steps to coding system so that the expired flag gets set to Y if the date is past the expiredate.?

assume server behavior code is required.

Does it belong in login page? or the successRedirect page?

Thanks for your time,

Gregg

Ray Borduin
04-14-2009, 08:25 AM
I would just create a view and calculate the Y/N value from the database directly.

SELECT *, (ExpDate < Now()) as IsExpired FROM table

or something similar to that. No reason to update the field if it can be calculated from fields that are already updated.

glmcps295424
04-14-2009, 06:24 PM
Ray,

Once I got the dates set up properly , I used the search with the results page to find records with an expiration date < date entered in search field. It's not automatic like I wanted but should work ok.

Thank You,

Gregg