concatenate database items then produce as a list

12 years 1 month ago #196240 by tgribble
hello.

is there any way to do this?

annually members will submit an image and or a reference which will change.( it is the bank reference for the payment of fees )

we need to be able to display the current field on the user profile and somehow collect all the previous years into another filed to produce a list.

ie

this year reference : REF7165278265

last year reference : REF0702753037
year before reference : REF 087301723

so fields stored would be

current : REF7165278265

history :
REF7165278265
REF0702753037
REF 087301723

does this make sense?

the same would go for the image url's

thanks

Please Log in to join the conversation.

12 years 1 month ago #196411 by krileon
I assume you're already handling the storage of these values, but simply need a way to display them on profile? I recommend incubator CB Query Field, which can display the results of a database SELECT query as a field value. You'd simply create 3 of them in your case for example.


Kyle (Krileon)
Community Builder Team Member
Before posting on forums: Read FAQ thoroughly + Read our Documentation + Search the forums
CB links: Documentation - Localization - CB Quickstart - CB Paid Subscriptions - Add-Ons - Forge
--
If you are a Professional, Developer, or CB Paid Subscriptions subscriber and have a support issue please always post in your respective support forums for best results!
--
If I've missed your support post with a delay of 3 days or greater and are a Professional, Developer, or CBSubs subscriber please send me a private message with your thread and will reply when possible!
--
Please note I am available Monday - Friday from 8:00 AM CST to 4:00 PM CST. I am away on weekends (Saturday and Sunday) and if I've missed your post on or before a weekend after business hours please wait for the next following business day (Monday) and will get to your issue as soon as possible, thank you.
--
My role here is to provide guidance and assistance. I cannot provide custom code for each custom requirement. Please do not inquire me about custom development.

Please Log in to join the conversation.

12 years 1 month ago - 12 years 1 month ago #196427 by tgribble
thanks for the reply

so,is there any way to "collect" the past entries ( references /image url's) into another field for archiving?

ie , when the current field is updated, the immediate past field is added to the year before, and the year before that etc, ie all the previous references / url's are stored to review at some time in the future.

i found this:
geekswithblogs.net/VBTips/archive/2008/04/25/how-to-append-to-a-sql-text-data-type-feild-again.aspx

Update [tableName] Set [myField] = [myField] + 'whatever' Where [id] = 1

would this work in a way with cb queries action? or auto actions?

thanks

Please Log in to join the conversation.

12 years 1 month ago #196445 by krileon

ie , when the current field is updated, the immediate past field is added to the year before, and the year before that etc, ie all the previous references / url's are stored to review at some time in the future.

You could do this with CB Auto Actions. Please search as I've provided conditions to check if a field has been changed or not already. You'll probably want to use a Fields action to simply updating a field with another fields value.


Kyle (Krileon)
Community Builder Team Member
Before posting on forums: Read FAQ thoroughly + Read our Documentation + Search the forums
CB links: Documentation - Localization - CB Quickstart - CB Paid Subscriptions - Add-Ons - Forge
--
If you are a Professional, Developer, or CB Paid Subscriptions subscriber and have a support issue please always post in your respective support forums for best results!
--
If I've missed your support post with a delay of 3 days or greater and are a Professional, Developer, or CBSubs subscriber please send me a private message with your thread and will reply when possible!
--
Please note I am available Monday - Friday from 8:00 AM CST to 4:00 PM CST. I am away on weekends (Saturday and Sunday) and if I've missed your post on or before a weekend after business hours please wait for the next following business day (Monday) and will get to your issue as soon as possible, thank you.
--
My role here is to provide guidance and assistance. I cannot provide custom code for each custom requirement. Please do not inquire me about custom development.

Please Log in to join the conversation.

12 years 1 month ago #196673 by tgribble
this is what i have tried thus far. any suggestions?

if the [cb_bankrefhistory] is empty, put [cb_bankref] in it

thanks
Attachments:

Please Log in to join the conversation.

12 years 1 month ago #196739 by krileon
You don't need to do a query. Just use a Field action and supply a value of [cb_bankref]. Your trigger also only applies to frontend profile edit so if you edit a user from backend it won't do anything.


Kyle (Krileon)
Community Builder Team Member
Before posting on forums: Read FAQ thoroughly + Read our Documentation + Search the forums
CB links: Documentation - Localization - CB Quickstart - CB Paid Subscriptions - Add-Ons - Forge
--
If you are a Professional, Developer, or CB Paid Subscriptions subscriber and have a support issue please always post in your respective support forums for best results!
--
If I've missed your support post with a delay of 3 days or greater and are a Professional, Developer, or CBSubs subscriber please send me a private message with your thread and will reply when possible!
--
Please note I am available Monday - Friday from 8:00 AM CST to 4:00 PM CST. I am away on weekends (Saturday and Sunday) and if I've missed your post on or before a weekend after business hours please wait for the next following business day (Monday) and will get to your issue as soon as possible, thank you.
--
My role here is to provide guidance and assistance. I cannot provide custom code for each custom requirement. Please do not inquire me about custom development.

Please Log in to join the conversation.

Moderators: beatnantkrileon
Time to create page: 0.225 seconds

Facebook Twitter LinkedIn