CONCATing a field for a report

Questions related to nuBuilder Forte Reports and the Report Builder.

CONCATing a field for a report

Postby mikep345678 » Sat Jan 20, 2018 8:26 am

I need, in a report I'm building, to combine two columns (cust_LastName and cust_FirstName), into one report field (to be used as a group header and report ORDER BY-- I don't want the report simply sorted by "cust_LastName", I want it sorted and grouped by "cust_LastName, cust_FirstName").

In other places (for example, browse forms and select boxes on forms), I've been able to specify the SQL statement CONCAT(cust_LastName,", ",cust_FirstName) and it's worked well. For example:
Screen Shot 2018-01-19 at 4.50.03 PM.png
Screen Shot 2018-01-19 at 4.50.03 PM.png (97.23 KiB) Viewed 853 times

However, I'm not finding a way to do this for a report field. I've tried making the report's underlying SQL include CONCAT AS Name, but that gets blown out when the SQL Builder closes. I've tried adding a field in the Fast Reports builder then changing the Field Name column to the desired SQL statement, but that causes PHP errors when I try to run the report and causes the report to not be editable (the window opened when the Report Designer button is clicked, is blank.)

Is there any way to do what I'm wanting to do?

Thank you!
Posts: 14
Joined: Tue Jan 16, 2018 4:23 am

Re: CONCATing a field for a report

Postby admin » Sat Jan 20, 2018 4:17 pm


I've tried to answer this question in your related post.

Site Admin
Posts: 3070
Joined: Mon Jun 15, 2009 9:53 am

Return to Reports