AMTI
Member
I just ran into a problem:
I have a form that needs to have the current row ID concatenated with a prefix. I'd like to have it in a new record but i'll settle by hiding it until the record is recorded.
I used the Calc Element to produce the following in the calculation:
But it will not return the correct calculation, until after a edit and not save. In other words. I have to save the record. Edit it and save it again for any ID to show up in my concatenation.
So, my question is: Is there a way to grab a literal mysql current row number on a potential new record row and save it into the form without using the {tablename___field} method and how? Or any other method of getting to my goal would be great.
Is there a beter way of handling this than calc? I thought about using display but i don't understand Eval (yes/no) and default with that element.
Thanks in advance,
Trip
I have a form that needs to have the current row ID concatenated with a prefix. I'd like to have it in a new record but i'll settle by hiding it until the record is recorded.
I used the Calc Element to produce the following in the calculation:
PHP:
$number = 'ECN-';
$number .= '{eng_eco_request___id}';
return $number;
But it will not return the correct calculation, until after a edit and not save. In other words. I have to save the record. Edit it and save it again for any ID to show up in my concatenation.
So, my question is: Is there a way to grab a literal mysql current row number on a potential new record row and save it into the form without using the {tablename___field} method and how? Or any other method of getting to my goal would be great.
Is there a beter way of handling this than calc? I thought about using display but i don't understand Eval (yes/no) and default with that element.
Thanks in advance,
Trip