- Posts: 604
- Thank you received: 82
Validator Conditional Execution
- bruce.gibbins
- Topic Author
- Offline
- Platinum Member
-
Less
More
2 weeks 12 hours ago - 2 weeks 12 hours ago #23015
by bruce.gibbins
Validator Conditional Execution was created by bruce.gibbins
Hi
Looking for some ideas
We have a validator in a transformation that has to check if a combination of values exists in a database table. I need a couple of things.
* If the record does not exist then I need to ABORT... But I'd like to set a package variable that can then influence workflow in the parent package.
* Not all rows in the source file need to be validated. If a certain value appears in a specific column (there could be a couple of columns) then the SQL Lookup doesn't need to occur, and the row can be pushed on to the next step in the Transformation. However, if the row has values NOT in this exclusion list then the SQL Lookup does need to occur and if the Lookup fails then the Transformation should ABORT.
* BUT because the transformation could FAIL for other reasons, we still need the parent package to know the difference between this specific SQL Lookup ABORT and an actual Failure or ABORT from another part of the transformation
I have a few ideas but just wanted to throw it out there to see what ideas may exist.
A diagram of what i am talking about is attached
cheers
Looking for some ideas
We have a validator in a transformation that has to check if a combination of values exists in a database table. I need a couple of things.
* If the record does not exist then I need to ABORT... But I'd like to set a package variable that can then influence workflow in the parent package.
* Not all rows in the source file need to be validated. If a certain value appears in a specific column (there could be a couple of columns) then the SQL Lookup doesn't need to occur, and the row can be pushed on to the next step in the Transformation. However, if the row has values NOT in this exclusion list then the SQL Lookup does need to occur and if the Lookup fails then the Transformation should ABORT.
* BUT because the transformation could FAIL for other reasons, we still need the parent package to know the difference between this specific SQL Lookup ABORT and an actual Failure or ABORT from another part of the transformation
I have a few ideas but just wanted to throw it out there to see what ideas may exist.
A diagram of what i am talking about is attached
cheers
Last edit: 2 weeks 12 hours ago by bruce.gibbins.
The following user(s) said Thank You: Peter.Jonson
Please Log in or Create an account to join the conversation.
- Peter.Jonson
-
- Offline
- Platinum Member
-
1 week 6 days ago #23017
by Peter.Jonson
Peter Jonson
ETL Developer
Replied by Peter.Jonson on topic Validator Conditional Execution
We will have a look at this one for you
Peter Jonson
ETL Developer
Please Log in or Create an account to join the conversation.
1 week 4 days ago #23020
by admin
Mike
ETL Architect
Replied by admin on topic Validator Conditional Execution
1 If the record does not exist then I need to ABORT... But I'd like to set a package variable that can then influence workflow in the parent package.
Right now the only option is to use "MagicToken"
Here is how:
begin
if [F001]='1' then
begin
SetVariable('<VariableName>','Value');
raise;
end;
Result:=[F001];
end;
Right now the only option is to use "MagicToken"
Here is how:
begin
if [F001]='1' then
begin
SetVariable('<VariableName>','Value');
raise;
end;
Result:=[F001];
end;
Mike
ETL Architect
Please Log in or Create an account to join the conversation.
1 week 4 days ago #23021
by admin
Mike
ETL Architect
Replied by admin on topic Validator Conditional Execution
Mike
ETL Architect
Please Log in or Create an account to join the conversation.
1 week 4 days ago #23022
by admin
Mike
ETL Architect
Replied by admin on topic Validator Conditional Execution
* Not all rows in the source file need to be validated. If a certain value appears in a specific column (there could be a couple of columns) then the SQL Lookup doesn't need to occur, and the row can be pushed on to the next step in the Transformation. However, if the row has values NOT in this exclusion list then the SQL Lookup does need to occur and if the Lookup fails then the Transformation should ABORT.
>>> Use a validator to redirect the records which do require SQL Lookup execution
>>> Use a validator to redirect the records which do require SQL Lookup execution
Mike
ETL Architect
Please Log in or Create an account to join the conversation.
2 days 14 hours ago #23046
by admin
Mike
ETL Architect
Replied by admin on topic Validator Conditional Execution
Just letting you know that in the latest release of Advanced ETL Processor, we have added "Set Package Variable" option to the lookup function
We are planning to do the same for the rest of the validation function but it is a lot of work so it will take a while
We are planning to do the same for the rest of the validation function but it is a lot of work so it will take a while
Mike
ETL Architect
The following user(s) said Thank You: bruce.gibbins
Please Log in or Create an account to join the conversation.