Query a Value on Registration

12 years 1 month ago #192242 by mike5151
Query a Value on Registration was created by mike5151
Joomla 2.5.1
CB 1.8
CB Subs 1.3.0RC1

I have a client who has several thousand existing members of their organisation (labour union) - at present they have no website or electronic communications - approximately 10% have known email addresses.

We have built the website and are now preparing the registration process for them.

On registration the client would like to validate each registration (before getting to the email verification process) by asking the members to enter their First Name, Last Name and Union membership No and having that data checked against the expected values for that member. If the data matches then the member proceeds with the rest of the registration - if not then they're binned out of the process and given a contact form to get their data checked.

The first name, last name, membership no data is currently just in an excel spreadhsheet.

What is your recommendation on the best way to acheive this?

kind regards

Mike

Please Log in to join the conversation.

12 years 1 month ago #192273 by krileon
Replied by krileon on topic Re: Query a Value on Registration
First you'll need to move the data from an excel spreadsheet to a database table within your Joomla database. You should be able to export it to a format phpmyadmin can understand making it a bit easier to import. I recommend just a 4 column table or id, firstname, lastname, membershipid or something similar.

You could then use incubator project CB Database Lookup Field to validate your users input registration information to your new database table that lists all their data.

forge.joomlapolis.com/projects/cb-cbdblookupfield?jump=welcome


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.
The following user(s) said Thank You: mike5151

Please Log in to join the conversation.

12 years 1 month ago #192292 by mike5151
Replied by mike5151 on topic Re: Query a Value on Registration
You have specified 'within the Joomla Database' - no problem with that but wondered if this would also work if the DB was outside the Joomla DB? Just thinking of another application.

Please Log in to join the conversation.

12 years 1 month ago - 12 years 1 month ago #192304 by krileon
Replied by krileon on topic Re: Query a Value on Registration

no problem with that but wondered if this would also work if the DB was outside the Joomla DB? Just thinking of another application.

I've yet to use the CB Database Lookup Field plugin, but believe it supports external and internal databases so I suppose you could use a database outside of Joomla.


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 #192339 by nant
Replied by nant on topic Re: Query a Value on Registration

krileon wrote:

no problem with that but wondered if this would also work if the DB was outside the Joomla DB? Just thinking of another application.

I've yet to use the CB Database Lookup Field plugin, but believe it supports external and internal databases so I suppose you could use a database outside of Joomla.


No, currently it does not support external databases - planned for next version.
The following user(s) said Thank You: krileon

Please Log in to join the conversation.

12 years 1 month ago #192621 by mike5151
Replied by mike5151 on topic Re: Query a Value on Registration
Some guidance required here from an absolute beginner with MySQL.

I have created a new table in the Joomla Database and uploaded the existing membership data. The new table is called `u76wz_union_membership', with column headings of 'ID', 'union_first', 'union_last' and 'union_member_no'. I have installed CB Database Lookup, enabled it and am now trying to create the query.

The workflow that I envisage is that the new user will complete their First name, Last Name and then at the DB lookup field they will be asked to input their membership no. The DB query will then check that the value entered matches 'union_member_no' and 'union_last' from `u76wz_union_membership'.

That's where I get a little stuck - so far my query reads:

SELECT * FROM `u76wz_union_membership` WHERE `union_member_no`= '[value]' AND `union_last` = '0'

Clearly, "`union_last` = '0'" is inadequate as it needs to reference the value in the 'Last_name' field that has been entered by the member on registration. I imagine that with the answer to that I will also be able to complete the SQL query update and SQL query rollback update.

Now that brings me to my next question, with the answer 'yes', the data matches and the query is successful, how do I use that result to allow or disallow the registration process to continue?

Many thanks

Mike

Please Log in to join the conversation.

Moderators: beatnantkrileon
Time to create page: 0.352 seconds

Facebook Twitter LinkedIn