FQL v4 will be decommissioned on June 30, 2025. Ensure that you complete your migration from FQL v4 to FQL v10 by that date.

Fauna accounts created after August 21, 2024 must use FQL v10. These accounts will not be able to run FQL v4 queries or access the v4 Dashboard.

For more details, see the v4 EOL announcement and migration guide. Contact support@fauna.com with any questions.

UpperCase

This reference topic applies to FQL v4. Go to this page for the latest FQL v10 reference topics.

UpperCase( value )
uppercase( value )
UpperCase( value )
UpperCase( value )
UpperCase( value )
UpperCase( value )

Description

The UpperCase function returns a string which has all lowercase characters in the string replaced by their corresponding uppercase characters.

Parameters

Parameter Type Definition and Requirements

value

String

The String to be converted to uppercase.

Returns

A String which has all characters from value converted to uppercase.

Examples

The following query executes an array of independent UpperCase operations and returns the results in an array. The result array position matches the execution array position. The first operation takes the string "FiRe" and converts all characters in the string to uppercase. The resultant object "FIRE" is placed in the top position of the result array. The second operation uses the string "FiRe And FireMan" and converts all characters to uppercase. The new uppercase string is placed in the second position of the result array.

client.query(
  [
    q.UpperCase('FiRe'),
    q.UpperCase('Fire And FireMan'),
  ]
)
.then((ret) => console.log(ret))
.catch((err) => console.error(
  'Error: [%s] %s: %s',
  err.name,
  err.message,
  err.errors()[0].description,
))
[ 'FIRE', 'FIRE AND FIREMAN' ]
result = client.query(
  [
    q.uppercase("FiRe"),
    q.uppercase("Fire And FireMan")
  ]
)
print(result)
['FIRE', 'FIRE AND FIREMAN']
result, err := client.Query(
	f.Arr{
		f.UpperCase("FiRe"),
		f.UpperCase("Fire And FireMan"),
	})

if err != nil {
	fmt.Fprintln(os.Stderr, err)
} else {
	fmt.Println(result)
}
[FIRE FIRE AND FIREMAN]
try
{
    Value result = await client.Query(
        Arr(
            UpperCase("FiRe"),
            UpperCase("Fire And FireMan")
        )
    );

    Console.WriteLine(result);
}
catch (Exception e)
{
    Console.WriteLine($"ERROR: {e.Message}");
}
Arr(StringV(FIRE), StringV(FIRE AND FIREMAN))
System.out.println(
    client.query(
        Arr(
            UpperCase("FiRe"),
            UpperCase("Fire And FireMan")
        )
    ).get());
["FIRE", "FIRE AND FIREMAN"]
[
  UpperCase('FiRe'),
  UpperCase('Fire And FireMan'),
]
[ 'FIRE', 'FIRE AND FIREMAN' ]
Query metrics:
  •    bytesIn:  55

  •   bytesOut:  40

  • computeOps:   1

  •    readOps:   0

  •   writeOps:   0

  •  readBytes:   0

  • writeBytes:   0

  •  queryTime: 3ms

  •    retries:   0

Is this article helpful? 

Tell Fauna how the article can be improved:
Visit Fauna's forums or email docs@fauna.com

Thank you for your feedback!