Hi All,
I have a form based on a table with FirstName and LastName, I want the
form to have a dropdown with SELECT CONCAT(FirstName,",",LastName)
Is there a way to do this?
Thanks!
Best,
Joel
Hi All,
I have a form based on a table with FirstName and LastName, I want the
form to have a dropdown with SELECT CONCAT(FirstName,",",LastName)
Is there a way to do this?
Thanks!
Best,
Joel
Hi,
Assuming it is SQL, concat has 2 arguments so concat(FirstName,concat(' , ',LastName))
Does this help (Oracle SQL Syntax)
Liebe Grüße / Yours,
Florian Reisinger
Just not sure where to place that in the form - I saw that it's in
theory possible with SQL - just not sure how to make it a part of the
dropdown.
Hi Joel
I have a form based on a table with FirstName and LastName, I want the
form to have a dropdown with SELECT CONCAT(FirstName,",",LastName)Is there a way to do this?
Create a listbox form control. Enter the properties of the control
(right mouse button click on empty part of form, context menu >
Control). In the Data tab, bind your control to the SQL query by
choosing SQL or SQL native from the List content type, then enter your
SQL statement in the field below, or alternatively, click on the
ellipsis and navigate to a query you have already saved.
Alex
Addenda :
Or, as I found out with a listbox, instead of a combobox, clicking on
the ellipsis takes you to the SQL query designer in SQL mode (even
better IMHO).
Alex
Hi All,
I have a form based on a table with FirstName and LastName, I want the
form to have a dropdown with SELECT CONCAT(FirstName,",",LastName)Is there a way to do this?
Thanks!
Best,
Joel
If you want to pick one distinct "Persons"."ID" from a listbox, get the
list box properties, tab [Data] and fill out like this:
Linked Field: Person_ID (name of the form's foreign key pointing to a
person in a persons table)
Source type: SQL
Source:
SELECT "LastName"||','||"FirstName"||','||"BirthDate" As "Visible", "ID"
FROM "Persons"
ORDER BY "Visible"
Bound field: 1 (the primary key ID from the persons table)
alternatively:
Source type: Query
Source: name of the query representing the above SELECT statement.
Tons of tutorials and examples:
in particular [Example] Relations reflected by list boxes in forms