Table of Contents

Search

  1. Preface
  2. Introduction to Informatica Big Data Management
  3. Mappings in the Hadoop Environment
  4. Mapping Sources in the Hadoop Environment
  5. Mapping Targets in the Hadoop Environment
  6. Mapping Transformations in the Hadoop Environment
  7. Processing Hierarchical Data on the Spark Engine
  8. Configuring Transformations to Process Hierarchical Data
  9. Processing Unstructured and Semi-structured Data with an Intelligent Structure Model
  10. Stateful Computing on the Spark Engine
  11. Monitoring Mappings in the Hadoop Environment
  12. Mappings in the Native Environment
  13. Profiles
  14. Native Environment Optimization
  15. Cluster Workflows
  16. Connections
  17. Data Type Reference
  18. Function Reference
  19. Parameter Reference

Big Data Management User Guide

Big Data Management User Guide

Complex Functions

Complex Functions

A complex function is a type of pre-defined function in which the value of the input or the return type is of a complex data type. The transformation language includes complex functions for complex data types. Use complex functions to generate and process hierarchical data.
The following table describes the complex functions for array data type:
Complex Function
Description
ARRAY (
element1
[,
element2
] ... )
Generates an array with the specified elements. The data type of the argument determines the data type of the array.
COLLECT_LIST (
value
)
Returns an array with elements in the specified port. The data type of the argument determines the data type of the array. COLLECT_LIST is an aggregate function.
CONCAT_ARRAY (' ',
array_of_strings
)
Concatenates string elements in an array based on a separator that you specify and returns a string.
SIZE (
array
)
Returns the size of the array.
The following table describes the complex functions for map data type:
Complex Function
Description
MAP (
key1, value1
[,
key2, value2
] ... )
Generates a map with elements based on the specified key-value pair. The data type of arguments determines the data type of the map elements.
MAP_FROM_ARRAYS (
key_array
,
value_array
)
Generates a map from the specified key and value arrays. The data type of arguments determines the data type of the map elements.
MAP_KEYS (
map
)
Returns an array of keys for the specified map.
MAP_VALUES (
map
)
Returns an array of values for the specified map.
COLLECT_MAP (
value
)
Returns a map with elements based on the specified arguments. The data type of the argument determines the data type of the map. COLLECT_LIST is an aggregate function.
SIZE (
map
)
Returns the size of the map.
The following table describes the complex functions for struct data type:
Complex Function
Description
STRUCT_AS (
type_definition
,
struct
)
Generates a struct with a schema based on the specified complex data type definition and the values you pass as argument.
STRUCT (
element_name1
,
value1
)
Generates a struct with the specified names and values for the elements. The data type of the value is based on the specified value argument.
RESPEC (
type_definition
,
struct
)
Renames each element of the given struct value based on the names of the elements in the specified complex data type definition.
CAST (
type_definition
,
struct
)
Changes the data type and the name of each element for the given struct value based on the corresponding data type and name of the element in the specified complex data type definition.
For more information about the function syntax, return value, and examples, see the
Informatica Developer Transformation Language Reference
.

0 COMMENTS

We’d like to hear from you!