Thank you! That worked. Here is what I did:
# $_bill is set as a fetchrow_hashref from the mysql db. ($_billUser_month,$_billUser_day,$_billUser_Year) = split /\//, $_bill +->{orig_day}, 3; $_add_Months = $_bill->{months_active} + 1; ($_billUser_Year,$_billUser_month,$_billUser_day) = Add_Delta_YM($ +_billUser_Year,$_billUser_month,$_billUser_day, 0,$_add_Months); ($_billUser_Year,$_billUser_month,$_billUser_day) = Add_Delta_Days($_b +illUser_Year,$_billUser_month,$_billUser_day, -5); $_nextBillingDate = sprintf("%02d/%02d/%02d",$_billUser_month,$_billUs +er_day,$_billUser_Year); $dbh->do(qq{UPDATE `subscription_users` SET `day` = ?, months_active = + months_active + 1 WHERE `id` = ?}, undef, $_nextBillingDate, $_billU +ser_id);
That way I am always basing the billing day off the original month. That way the billing DAY don't ever change, like going from 31 one month, to 30 then it would stay 30 because the next date is based on 30... Anyhow, thank you so much!!


Thanks again!
RJEnterprises

In reply to Re^2: Adding to dates by Anonymous Monk
in thread Adding to dates by Anonymous Monk

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.