Forum Discussion
mabond12
Jun 10, 2023Copper Contributor
SQL query for concatenating field value of two records
Hello, I have a table with records of individuals (a surname and a forename field for each) with unique id's for each individual. Each record also has a field with a value for a family id. In cases where two individuals are married or partners they will have the same family id but different surnames, forenames and person-id's. I want my query to be able to select the two records with the matching family-id's and give me a single record result with the forenames and surnames concatenated in a single field so we get a result like "Joe Bloggs and Wilma Flintstone".
Thanks and regards
Michael Bond
- olafhelperBronze ContributorThat's really to less on information.
Please post table design as DDL, some sample data as DML statement and the expected result.