Knowledgebase articles
- Welcome to the Knowledge Base
- Introduction
- Our Approach to Accessibility
- Getting Started
- Preferences
- Activities
- Cases
- Introduction to Cases
- Displaying & Adding Cases
- Managing Cases
- Using the Case Portal
- Email
- Importing Data
- Leads
- Marketing
- Introduction to Marketing
- Event Management
- Compliance Records
- Force24
- Spotler Integration
- What is Spotler?
- Navigating your Spotler homepage
- Introduction to GatorMail
- GatorMail Configuration
- Sending Emails in GatorMail
- Advanced Features
- Setting up the Plugin
- Viewing Web Insights Data on your Form Layouts
- Domain Names and Online Activities
- Reporting incorrect Leads created through Web Insights
- Reporting on Web Insights data
- Using UTM Values
- Why aren’t Online Activities being created in the database?
- Why is GatorLeads recording online activities in a foreign language?
- GatorSurvey
- GatorPopup
- Integrations
- SFTP/FTP Processes
- Mapping
- DocuSign Functionality
- DocuSign – Worked Examples
- DocuSign – Reporting
- Adobe Sign Integration
- Zapier
- Introduction to Zapier
- Available Triggers and Actions
- Linking your Workbooks Account to Zapier
- Posted Invoices to Xero Invoices
- Xero payments to Workbooks Tasks
- New Case to Google Drive folder
- New Case to Basecamp Project
- New Workbooks Case to JIRA Ticket
- Jira Issue to new Case
- 123FormBuilder Form Entry to Case
- Eventbrite Attendee to Sales Lead and Task
- Facebook Ad Leads to Sales Leads
- Wufoo Form Entry to Sales Lead
- Posted Credit Note to Task
- Survey Monkey responses to Tasks
- Multistep Zaps
- Email Integrations
- Microsoft Office
- Auditing
- Comments
- People & Organisations
- Introduction to People & Organisations
- Using Postcode Lookup
- Data Enrichment
- Reporting
- Using Reports
- Advanced Reporting
- Transaction Documents
- Displaying & Adding Transaction Documents
- Copying Transaction Documents
- Transaction Documents Fields Help
- Transaction Documents Line Items Help
- Printing & Sending Transaction Documents
- Managing Transaction Document Currencies
- Managing Transaction Document Statuses
- Setting a Blank Default Currency on Transaction Documents
- Credit Notes
- Customer Orders
- Invoices
- Quotations
- Supplier Orders
- Sagelink
- Configuration
- Contact Support
- Releases & Roadmap
Separating a multi-line address field into separate reporting columns
Last updated : 18th July 2025
Occasionally Workbooks users want to export people data in order to merge it into a hard copy mailshot. In these circumstances there is a requirement to show the different lines of a multi-line address field in separate columns in a report so that it can be exported easily to Excel. This is possible to do by using a substring formula in your Workbooks report. The same technique can be used to split the contents of other multi-line text fields into different columns but for this example the focus is on the street address.
1 | Create a report based on People |
2 | Add a calculated column for the first line of the address using the following formula: |
TRIM(REPLACE(RIGHT(SUBSTRING_INDEX( main_street_address, '\n', 1), LENGTH(SUBSTRING_INDEX( main_street_address, '\n', 1))- LENGTH(SUBSTRING_INDEX( main_street_address, '\n', 0))), ',' ,'')) | |
3 | Add a calculated column for the second line of the address using the following formula: |
TRIM(REPLACE(RIGHT(SUBSTRING_INDEX( main_street_address, '\n', 2), LENGTH(SUBSTRING_INDEX( main_street_address, '\n', 2))- LENGTH(SUBSTRING_INDEX( main_street_address, '\n', 1))-1), ',' ,'')) | |
4 | Continue adding calculated columns until you've accommodated the maximum number of rows in any of your address fields (typically 4 or 5 but each database can be different). For each subsequent row, use the formula shown for the second line but increment the number highlighted in yellow by one each time. So, for example, the formula for the third line of the address would be: |
TRIM(REPLACE(RIGHT(SUBSTRING_INDEX( main_street_address, '\n', 3), LENGTH(SUBSTRING_INDEX( main_street_address, '\n', 3))- LENGTH(SUBSTRING_INDEX( main_street_address, '\n', 2))-1), ',' ,'')) |
Was this content useful?