Skip to content
View in the app

A better way to browse. Learn more.

FMForums.com

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Calculation field - how to

Featured Replies

Hi there.

I am trying to list off authors in a database file.

I effectively have four fields and am unsure how to tie them together for a list.

First repeating field is text: authors_last_name

Second repeating field is text: authors_initial

Third field: book_name

Fourth field is: concatenated version of first three fields.

What Im trying to achieve is where there are two or more authors for any given book. Normally I would just field & field to concatenate them, but need to formulate it so that the single or multiple authors are listed as

Smith, J. Brown, S.

I then went on to want to add a single quote around the title - not sure how to do this - i thought adding a CHR() equivalent would be good.

I also want the title in italics - possible to do this on the fly?

Last effect thats bugging me is that some times the text line is long (long title and several authors), and sometimes short. How do I setup a field for Preview Mode where the lines are evenly spaced regardless of the length of the text?

This is several points together... may be I should ask them seperately?...

Any help would be appreciated.

Greg, DO NOT USE REPEATING FIELDS TO SIMULATE A RELATIONAL STRUCTURE!!

To add a single quote: "'"

To make text Italic: TextStyleAdd( Text ; Italic)

The reformatting you could probably cheat with, have a calculated field that converts the author's name james smith to smith J. i.e. LeftWords( name ; 1 ) & ", " & Left( RightWords( name ; 1 ) ; 1 ) & "."

Next, create a calc field in your primary table that just goes:

Substitute( List ( authors::nameCalc ) ; ¶ ; " " )

Anyway, the above will only work in a relational structure, do not use repeating fields to emulate.

  • Author

OK - thanks for the advice re relational database GenX - I'll restructure what I have.

I tried the single quote thing but it draws double quotes instead - I thought Id have to do the URL thing of wordone%20wordtwo type thing, but you reckon that "'" will worl.

Cheers,

Greg

Create an account or sign in to comment

Important Information

By using this site, you agree to our Terms of Use.

Account

Navigation

Search

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.