Personal tools

Log in

Changes

From All n One's bxp software Wixi

Jump to: navigation, search

MetaData - Processing Rules - String Management

9,320 bytes added, 21:54, 7 February 2017
Created page with "= Overview = For more information on {| class="wikitable" ! Area ! Link |- | MetaData please refer here || MetaData_-_Start_Here |- | Processing rules please refer here..."
= Overview =

For more information on

{| class="wikitable"
! Area
! Link
|-
| MetaData please refer here || [[MetaData_-_Start_Here]]
|-
| Processing rules please refer here || [[MetaData_Process_Rules]]
|-
| Parameter construction please refer here || [[MetaData_Program_and_Outcomes]]
|-
|}

= Reference =

This wixi article is meant to serve as a reference guide to a subset of MetaData Processing Rules.


= Rules =


== Append ==


The append rule allows for any string to be appended to the end of an existing string stored in a Database field.

Required fields to execute rule:
# Rule Name
# Form id (the same as the current sequence)
# Field to store the end result
# Field that contains the string to append the new string to
# New string to append

Example:
<tt>
Rule Name[[-SEP-]]Form Id[[-SEP-]]Destination field[[-SEP-]]Filed containing live value[[-SEP-]]String to append[[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]]
</tt>

Example (with replacement values):
<tt>
Append[[-SEP-]]1[[-SEP-]]strCDA_1_field_0_1[[-SEP-]]strCDA_1_field_0_2[[-SEP-]]Add This String To The End[[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]]
</tt>

== Prepend ==

The prepend rule allows for any string to be appended to the start of an existing string stored in a Database field.
Required fields to execute rule:
1) Rule Name
2) Form id (the same as the current sequence)
3) Field to store the end result
4) Field that contains the string to prepend the new string to
5) New string to append
Example:
Rule Name[[-SEP-]]Form Id[[-SEP-]]Destination field[[-SEP-]]Filed containing live value[[-SEP-]]String to prepend[[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]]

Example (with replacement values):
Prepend[[-SEP-]]1[[-SEP-]]strCDA_1_field_0_1[[-SEP-]]strCDA_1_field_0_2[[-SEP-]]Add This String To The Start[[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]]

9.4 Encapsulate

The encapsulate rule allows for any string to be to be added to and surround the contents of an existing string stored in a Database field.
Required fields to execute rule:
1) Rule Name
2) Form id (the same as the current sequence)
3) Field to store the end result
4) Field that contains the string to encapsulate the new string with
5) New string to append
Example:
Rule Name[[-SEP-]]Form Id[[-SEP-]]Destination field[[-SEP-]]Filed containing live value[[-SEP-]]String to encapsulate[[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]]

Example (with replacement values):
Encapsulate[[-SEP-]]1[[-SEP-]]strCDA_1_field_0_1[[-SEP-]]strCDA_1_field_0_2[[-SEP-]]Surround With This[[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]]

9.5 Remove Numbers

The remove numbers rule simply removes all numbers from the contents of an existing string stored in a Database field.

Required fields to execute rule:
1) Rule Name
2) Form id (the same as the current sequence)
3) Field to store the end result
4) Field that contains the string to remove number from
5) New string to append
Example:
Rule Name[[-SEP-]]Form Id[[-SEP-]]Destination field[[-SEP-]]Filed containing live value[[-SEP-]] [[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]]

Example (with replacement values):
RemoveNumbers[[-SEP-]]1[[-SEP-]]strCDA_1_field_0_1[[-SEP-]]strCDA_1_field_0_2[[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]]

9.6 Strip Tags

The strip tags rule simply removes all HTML tags (<br/>, <b>, <table>, </table> etc.) from the contents of an existing string stored in a Database field.

Required fields to execute rule:
1) Rule Name
2) Form id (the same as the current sequence)
3) Field to store the end result
4) Field that contains the string to remove HTML tags from
5) New string to append
Example:
Rule Name[[-SEP-]]Form Id[[-SEP-]]Destination field[[-SEP-]]Filed containing live value[[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]]

Example (with replacement values):
StripTags[[-SEP-]]1[[-SEP-]]strCDA_1_field_0_1[[-SEP-]]strCDA_1_field_0_2[[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]]

9.7 Replace

The replace rule simply allows for the replacement of a string with another from the contents of an existing string stored in a Database field.

Required fields to execute rule:
1) Rule Name
2) Form id (the same as the current sequence)
3) Field to store the end result
4) Field that contains the string to attempt the replacement on
5) Value to search for
6) Value to replace with
Example:
Rule Name[[-SEP-]]Form Id[[-SEP-]]Destination field[[-SEP-]]Filed containing live value[[-SEP-]]Field to attempt replacement on[[-SEP-]]Value to search for[[-SEP-]]Value to Replace with[[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]]

Example (with replacement values):
Replace[[-SEP-]]1[[-SEP-]]strCDA_1_field_0_1[[-SEP-]]strCDA_1_field_0_2[[-SEP-]] strCDA_1_field_0_3[[-SEP-]]Find This[[-SEP-]]Replace With This[[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]]

9.8 Concatenation

The concatenation rule simply allows for the combining of the contents of one database field with another within the same record of the same database

Required fields to execute rule:
1) Rule Name
2) Form id (the same as the current sequence)
3) Field to store the end result
4) Form id (the same as the current sequence)
5) First field to be concatenated
6) Form id (the same as the current sequence)
7) Spacer (string to separate the two fields)
8) Form id (the same as the current sequence)
9) Second filed to be concatenated

Example:
Rule Name[[-SEP-]]Form Id[[-SEP-]]Destination Field[[-SEP-]]Form Id[[-SEP-]]First Field[[-SEP-]][[-SEP-]]Form Id[[-SEP-]][[-SEP-]]Spacer[[-SEP-]]Form Id[[-SEP-]]Second Field[[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]]

Example (with replacement values):
Concat[[-SEP-]]1[[-SEP-]]strCDA_1_field_0_1[[-SEP-]]1[[-SEP-]]strCDA_1_field_0_2[[-SEP-]][[-SEP-]]1[[-SEP-]][[-SEP-]] - [[-SEP-]]1[[-SEP-]]strCDA_1_field_0_3[[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]]

9.9 Read From

The read from rule simply allows for the for the searching of a string for a search sting and if found remove every character before and including the search string

Required fields to execute rule:
1) Rule Name
2) Form id (the same as the current sequence)
3) Field to store the end result
4) Form id (the same as the current sequence)
5) Field to perform the searching on
6) Value to search with

Example:
Rule Name[[-SEP-]]Form Id[[-SEP-]]Destination field[[-SEP-]]Form ID[[-SEP-]]Field To Search [[-SEP-]]Value To Search For[[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]]

Example (with replacement values):
ReadFrom[[-SEP-]]1[[-SEP-]]strCDA_1_field_0_1[[-SEP-]]1[[-SEP-]]strCDA_428_field_0_2[[-SEP-]]Find This[[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]] 
9.10 Read Until

The read until rule simply allows for the for the searching of a string for a search sting and if found remove every character after and including the search string

Required fields to execute rule:
1) Rule Name
2) Form id (the same as the current sequence)
3) Field to store the end result
4) Form id (the same as the current sequence)
5) Field to perform the searching on
6) Value to search with

Example:
Rule Name[[-SEP-]]Form Id[[-SEP-]]Destination field[[-SEP-]]Form ID[[-SEP-]]Field To Search [[-SEP-]]Value To Search For[[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]]

Example (with replacement values):
ReadUntil[[-SEP-]]1[[-SEP-]]strCDA_1_field_0_1[[-SEP-]]1[[-SEP-]]strCDA_428_field_0_2[[-SEP-]]Find This[[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]] 
9.11 Set Value

The set value rule simply allows for a database field to be updated with a new string, defined in the MetaData Program.

Required fields to execute rule:
1) Rule Name
2) Form id (the same as the current sequence)
3) Field to store the end result
4) Form id (the same as the current sequence)
5) Value to insert

Example:
Rule Name[[-SEP-]]Form ID[[-SEP-]]Destination Field[[-SEP-]]Form Id[[-SEP-]][[-SEP-]]Value To Insert[[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]]

Example (with replacement values):
SetValue[[-SEP-]]1[[-SEP-]]strCDA_1_field_0_1[[-SEP-]]1[[-SEP-]][[-SEP-]]Add This Value[[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]][[-SEP-]]




[[Category:Topic:MetaData]]
[[Category:Module Specific:MetaData]]
7,528
edits