examples package also contains a couple of services that demonstrate how you
could transform data using Gloop. These services are stored
dataTransformation package and are described in the following table:
||Maps an array to a single object.|
||Maps a single object to an array.|
Like their names imply, these services deal with the conversion of data from one format to another.
Due to the limitations in HSQL, the following services could only work with specific SQL sources:
Please see the following articles for more information:
Under the Coder Navigator, expand the
examples package entry and navigate to the
code folder. Afterwards, look for the
dataTransformation package. This package contains the
files and/or directories shown below:
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21
examples ├── ... └── code └── ... └── dataTransformation ├── conf │ └── CreateSqlDatabase.gloop ├── sql │ ├── InsertBlob.gloop │ ├── InsertClob.gloop │ ├── SelectAllBlob.gloop │ ├── SelectBlob.gloop │ └── SelectClob.gloop ├── ArrayToSingleObject.gloop ├── DatabaseRecordToCSV.gloop ├── FileToInputStream.gloop ├── SingleObjectToArray.gloop ├── StringToBlob.gloop ├── StringToClob.gloop ├── StringToInputStream.gloop └── StringToReader.gloop
The primary services are located directly under the
dataTransformation package. These are the services that you should
open up or run to see data transformation examples.
StringToClob.gloop, you'll have to run
dataTransformation.conf, to setup the required database and tables.
dataTransformation.sql package contains Gloop SQL services used by some of the example services.
How It Works...
Simple transformations can be done simply by creating map lines between properties using the Mapper view. However, for more complex tasks, a custom strategy might be needed; typically, this would involve method calls.