- Posts: 3
- Thank you received: 0
Custom field SQL with Where clause
- Evolution Ways - Robert Riou
- Topic Author
- Offline
- New Member
-
Less
More
2 years 5 months ago - 2 years 5 months ago #154508
by Evolution Ways - Robert Riou
Custom field SQL with Where clause was created by Evolution Ways - Robert Riou
Hi Tuan,
I wish to pre-set fields in the checkout forms when a registered user checkout for an event.
By the way, the first and last name and email are already pre-set (but i don't know how....)
Is there a way to create a SQL custom field with a WHERE clause to get information related to the logged user (a Where clause which use the userId)
Regard,
Robert
I wish to pre-set fields in the checkout forms when a registered user checkout for an event.
By the way, the first and last name and email are already pre-set (but i don't know how....)
Is there a way to create a SQL custom field with a WHERE clause to get information related to the logged user (a Where clause which use the userId)
Regard,
Robert
Last edit: 2 years 5 months ago by Evolution Ways - Robert Riou.
Please Log in or Create an account to join the conversation.
- Tuan Pham Ngoc
- Offline
- Administrator
-
2 years 5 months ago #154511
by Tuan Pham Ngoc
Replied by Tuan Pham Ngoc on topic Custom field SQL with Where clause
Hello Robert
Where data for the registered user is stored? If you use Joomla core user profile or custom fields, or some of the supported third party extensions, then you can map the fields for the system to pre-fill the data. See eventbookingdoc.joomservices.com/basic-s...hronize-profile-data for more information
Tuan
Where data for the registered user is stored? If you use Joomla core user profile or custom fields, or some of the supported third party extensions, then you can map the fields for the system to pre-fill the data. See eventbookingdoc.joomservices.com/basic-s...hronize-profile-data for more information
Tuan
Please Log in or Create an account to join the conversation.
- Evolution Ways - Robert Riou
- Topic Author
- Offline
- New Member
-
Less
More
- Posts: 3
- Thank you received: 0
2 years 5 months ago #154515
by Evolution Ways - Robert Riou
Replied by Evolution Ways - Robert Riou on topic Custom field SQL with Where clause
Thanks Tuan for your quick and useful answer !

Please Log in or Create an account to join the conversation.
- Tuan Pham Ngoc
- Offline
- Administrator
-
2 years 5 months ago #154522
by Tuan Pham Ngoc
Replied by Tuan Pham Ngoc on topic Custom field SQL with Where clause
You're welcome

Please Log in or Create an account to join the conversation.
- OTWD
-
- Offline
- Platinum Member
-
Less
More
- Posts: 330
- Thank you received: 5
1 year 9 months ago #159284
by OTWD
Success consists of going from failure to failure without loss of enthusiasm.
Replied by OTWD on topic Custom field SQL with Where clause
Hi I'm trying to do the same thing whereby a registered user has a joomla custom field in their profile called "Location".
Using j!4.3.3 and EB 4.5.0
I'm using a Joomla Registration Field with the following sql:
The mapping works in the Billing form but its not mapped in the Group member form. Is there any way to get the mapping to work here too?
Alternatively it would be great to have a plugin that would recognise the id of the logged in user using a shortcode.
Then we could use a EB sql field:
does this option exist?
Using j!4.3.3 and EB 4.5.0
I'm using a Joomla Registration Field with the following sql:
Code:
SELECT id AS value, name AS text FROM #__eb_categories WHERE parent != 0
Alternatively it would be great to have a plugin that would recognise the id of the logged in user using a shortcode.
Then we could use a EB sql field:
Code:
SELECT id AS value, name AS text FROM #__eb_categories WHERE parent != 0 AND id = {$my->id}
Success consists of going from failure to failure without loss of enthusiasm.
Please Log in or Create an account to join the conversation.
- Tuan Pham Ngoc
- Offline
- Administrator
-
1 year 9 months ago #159292
by Tuan Pham Ngoc
Replied by Tuan Pham Ngoc on topic Custom field SQL with Where clause
Hello
If I understand your question correctly, you can use [USER_ID] tag in the SQL to get Joomla User ID of the registrant. So the SQL becomes:
Regards,
Tuan
If I understand your question correctly, you can use [USER_ID] tag in the SQL to get Joomla User ID of the registrant. So the SQL becomes:
Code:
SELECT id AS value, name AS text FROM #__eb_categories WHERE parent != 0 AND id = [USER_ID]
Regards,
Tuan
The following user(s) said Thank You: OTWD
Please Log in or Create an account to join the conversation.
- OTWD
-
- Offline
- Platinum Member
-
Less
More
- Posts: 330
- Thank you received: 5
1 year 9 months ago #159324
by OTWD
Success consists of going from failure to failure without loss of enthusiasm.
Replied by OTWD on topic Custom field SQL with Where clause
Awesome - didnt know this was possible - this is a game changer!!
Success consists of going from failure to failure without loss of enthusiasm.
Please Log in or Create an account to join the conversation.
- Tuan Pham Ngoc
- Offline
- Administrator
-
1 year 9 months ago #159328
by Tuan Pham Ngoc
Replied by Tuan Pham Ngoc on topic Custom field SQL with Where clause
That was supported from some time ago, I should have it better documented 
Tuan

Tuan
Please Log in or Create an account to join the conversation.
Moderators: Tuan Pham Ngoc
Support
Documentation
Information
Copyright © 2025 Joomla Extensions by Joomdonation. All Rights Reserved.
joomdonation.com is not affiliated with or endorsed by the Joomla! Project or Open Source Matters.
The Joomla! name and logo is used under a limited license granted by Open Source Matters the trademark holder in the United States and other countries.
The Joomla! name and logo is used under a limited license granted by Open Source Matters the trademark holder in the United States and other countries.