<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
		>
<channel>
	<title>Comments on: OMBPlus &#8211; Create mapping with operators</title>
	<atom:link href="http://www.it-eye.nl/weblog/2006/04/13/ombplus-create-mapping-with-operators/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.it-eye.nl/weblog/2006/04/13/ombplus-create-mapping-with-operators/</link>
	<description>Where Business meets IT</description>
	<lastBuildDate>Mon, 06 Sep 2010 06:08:59 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.9.2</generator>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
		<item>
		<title>By: Zsolt Numan</title>
		<link>http://www.it-eye.nl/weblog/2006/04/13/ombplus-create-mapping-with-operators/comment-page-1/#comment-262677</link>
		<dc:creator>Zsolt Numan</dc:creator>
		<pubDate>Wed, 25 Jun 2008 12:27:41 +0000</pubDate>
		<guid isPermaLink="false">http://www.it-eye.nl/weblog/?p=154#comment-262677</guid>
		<description>Hi Fred 
This blog is a big help for me.

I&#039;v just started to deal with OMB and need exactly the kind of script you&#039;v been 
working on: retrieve all properties for each mapping
Could you share that with me?
It saved me a lot of time.

Thanks&amp;Regards
Zsolt</description>
		<content:encoded><![CDATA[<p>Hi Fred<br />
This blog is a big help for me.</p>
<p>I&#8217;v just started to deal with OMB and need exactly the kind of script you&#8217;v been<br />
working on: retrieve all properties for each mapping<br />
Could you share that with me?<br />
It saved me a lot of time.</p>
<p>Thanks&amp;Regards<br />
Zsolt</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Fred Haeckl</title>
		<link>http://www.it-eye.nl/weblog/2006/04/13/ombplus-create-mapping-with-operators/comment-page-1/#comment-44808</link>
		<dc:creator>Fred Haeckl</dc:creator>
		<pubDate>Fri, 09 Mar 2007 20:38:54 +0000</pubDate>
		<guid isPermaLink="false">http://www.it-eye.nl/weblog/?p=154#comment-44808</guid>
		<description>I found the answer to my question looking at some other OMBRETRIEVE examples. As previously stated, I was using OMBRETRIEVE MAPPING ‘X’ GET OPERATORS which gave me all the operators. I found that you can specify what type of OPERATOR you are looking for (OMBRETRIEVE MAPPING ‘X’ GET TABLE OPERATORS) will only return the TABLE operators. OMBPLUS will return blank if there are none, w/o raising an error. So... based on the list of acceptable OPERATORS ---
ADVANCED_QUEUE, AGGREGATOR, CONSTANT, CUBE, DATA_GENERATOR,DEDUPLICATOR, DIMENSION, EXPRESSION, EXTERNAL_PROCESS, EXTERNAL_TABLE, FILTER, FLAT_FILE, INPUT_PARAMETER, JOINER, KEY_LOOKUP,MATCHMERGE, MATERIALIZED_VIEW, NAME_AND_ADDRESS, OUTPUT_PARAMETER, PIVOT, POSTMAPPING_PROCESS, PREMAPPING_PROCESS,
SEQUENCE, SET_OPERATION, SORTER, SPLITTER, TABLE, TRANSFORMATION,UNPIVOT, VIEW.
I can create a loop of each operator type, then another loop for each property of each operator and retrieve all my properties for each mapping.

Thanks - Fred</description>
		<content:encoded><![CDATA[<p>I found the answer to my question looking at some other OMBRETRIEVE examples. As previously stated, I was using OMBRETRIEVE MAPPING ‘X’ GET OPERATORS which gave me all the operators. I found that you can specify what type of OPERATOR you are looking for (OMBRETRIEVE MAPPING ‘X’ GET TABLE OPERATORS) will only return the TABLE operators. OMBPLUS will return blank if there are none, w/o raising an error. So&#8230; based on the list of acceptable OPERATORS &#8212;<br />
ADVANCED_QUEUE, AGGREGATOR, CONSTANT, CUBE, DATA_GENERATOR,DEDUPLICATOR, DIMENSION, EXPRESSION, EXTERNAL_PROCESS, EXTERNAL_TABLE, FILTER, FLAT_FILE, INPUT_PARAMETER, JOINER, KEY_LOOKUP,MATCHMERGE, MATERIALIZED_VIEW, NAME_AND_ADDRESS, OUTPUT_PARAMETER, PIVOT, POSTMAPPING_PROCESS, PREMAPPING_PROCESS,<br />
SEQUENCE, SET_OPERATION, SORTER, SPLITTER, TABLE, TRANSFORMATION,UNPIVOT, VIEW.<br />
I can create a loop of each operator type, then another loop for each property of each operator and retrieve all my properties for each mapping.</p>
<p>Thanks &#8211; Fred</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Fred Haeckl</title>
		<link>http://www.it-eye.nl/weblog/2006/04/13/ombplus-create-mapping-with-operators/comment-page-1/#comment-44477</link>
		<dc:creator>Fred Haeckl</dc:creator>
		<pubDate>Thu, 08 Mar 2007 17:11:43 +0000</pubDate>
		<guid isPermaLink="false">http://www.it-eye.nl/weblog/?p=154#comment-44477</guid>
		<description>I&#039;m trying to create a script that lists the values of each property for each operator. The code above for flat file is a great start, and for each operator type, I can get this list of properties. The problem I&#039;m having now is that OMBRETRIEVE MAPPING &#039;X&#039; GET OPERATORS tells me the name of the operator, but not the type. Is there a OPERATOR property that tells me what type of operator it is? If I try to pull a property such as &#039;RECORD_TYPE_START_POSITION&#039; for a TABLE OPERATOR, I receive an error. 

Any suggestions?

Thanks - Fred</description>
		<content:encoded><![CDATA[<p>I&#8217;m trying to create a script that lists the values of each property for each operator. The code above for flat file is a great start, and for each operator type, I can get this list of properties. The problem I&#8217;m having now is that OMBRETRIEVE MAPPING &#8216;X&#8217; GET OPERATORS tells me the name of the operator, but not the type. Is there a OPERATOR property that tells me what type of operator it is? If I try to pull a property such as &#8216;RECORD_TYPE_START_POSITION&#8217; for a TABLE OPERATOR, I receive an error. </p>
<p>Any suggestions?</p>
<p>Thanks &#8211; Fred</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Fred Haeckl</title>
		<link>http://www.it-eye.nl/weblog/2006/04/13/ombplus-create-mapping-with-operators/comment-page-1/#comment-21360</link>
		<dc:creator>Fred Haeckl</dc:creator>
		<pubDate>Sat, 16 Dec 2006 18:37:35 +0000</pubDate>
		<guid isPermaLink="false">http://www.it-eye.nl/weblog/?p=154#comment-21360</guid>
		<description>Thanks for the response. I have the documentation, but that&#039;s just it. The start_position is not even mentioned in the documentation for flat_files.
The way I found the correct property name was through the OWB UI.
Thanks again - Fred</description>
		<content:encoded><![CDATA[<p>Thanks for the response. I have the documentation, but that&#8217;s just it. The start_position is not even mentioned in the documentation for flat_files.<br />
The way I found the correct property name was through the OWB UI.<br />
Thanks again &#8211; Fred</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Ilona Tielke</title>
		<link>http://www.it-eye.nl/weblog/2006/04/13/ombplus-create-mapping-with-operators/comment-page-1/#comment-20201</link>
		<dc:creator>Ilona Tielke</dc:creator>
		<pubDate>Fri, 08 Dec 2006 10:46:50 +0000</pubDate>
		<guid isPermaLink="false">http://www.it-eye.nl/weblog/?p=154#comment-20201</guid>
		<description>Fred,

Unfortunatly, there is no option to get a list op Properties in OMBPLus. So, you&#039;ll need to keep using the doc&#039;s on OMBPlus. 

Depending on your OWB version, the code of OMBplus could be slidely different. For START_POSITION, which you were looking for, it is the same in OWB 10G R1 an OWB 10G R2.

I created some kind of summarize script which shows the different properties of a Flat_file. The script can be made more dynamic by using prompt to ask for a specific FLAT_FILE name but I leave that to you. What is does is that you first need to create a list with property names which you have to lookup first in the documentation. But then after placing those into your script you have a summary of all properties. See below script for an example.


&lt;code&gt;set ff_prop_list { DATA_FILE_NAME IS_DELIMITED CHARACTERSET RECORD_DELIMITER RECORD_LENGTH RECORD_TYPE_COLUMN_NUMBER RECORD_TYPE_START_POSITION RECORD_TYPE_END_POSITION NUMBER_OF_RECORDS_TO_SKIP FIELD_DELIMITER FIELD_LEFT_ENCLOSURE NUMBER_OF_PHYSICAL_RECORDS_PER_LOGICAL CONTINUE_IF_ENDS_WITH CONTINUE_IF_STARTS_WITH }

set record_prop_list { RECORD_TYPE_VALUE }

set field_prop_list { DATATYPE LENGTH PRECISION SCALE START_POSITION SQL_DATATYPE SQL_LENGTH SQL_PRECISION SQL_SCALE MASK NULL_IF DEFAULT_IF }

foreach ff_prop $ff_prop_list {
 set v_result  [ OMBRETRIEVE FLAT_FILE &#039;T999_KODE_DEF_TXT&#039; GET PROPERTIES($ff_prop) ];
 puts -nonewline &quot;Flat File property: $ff_prop is: $v_result \n&quot; 
}


foreach record_prop $record_prop_list {
 set v_result  [ OMBRETRIEVE FLAT_FILE &#039;T999_KODE_DEF_TXT&#039; RECORD &#039;T999_KODE_DEF_TXT&#039; GET PROPERTIES($record_prop) ];
 puts -nonewline &quot;Record property: $record_prop is: $v_result \n&quot; 
}

set field_list [ OMBRETRIEVE FLAT_FILE &#039;T999_KODE_DEF_TXT&#039; RECORD &#039;T999_KODE_DEF_TXT&#039; GET FIELDS ]

foreach field $field_list {
puts &quot;\n==== Field Properties of FIELD: $field ==== \n&quot;
foreach field_prop $field_prop_list {
 set v_result  [ OMBRETRIEVE FLAT_FILE &#039;T999_KODE_DEF_TXT&#039; RECORD &#039;T999_KODE_DEF_TXT&#039; FIELD &#039;$field&#039; GET PROPERTIES($field_prop) ];
 puts -nonewline &quot;Field property: $field_prop is: $v_result \n&quot; 
}
}&lt;/code&gt;

Regards, Ilona</description>
		<content:encoded><![CDATA[<p>Fred,</p>
<p>Unfortunatly, there is no option to get a list op Properties in OMBPLus. So, you&#8217;ll need to keep using the doc&#8217;s on OMBPlus. </p>
<p>Depending on your OWB version, the code of OMBplus could be slidely different. For START_POSITION, which you were looking for, it is the same in OWB 10G R1 an OWB 10G R2.</p>
<p>I created some kind of summarize script which shows the different properties of a Flat_file. The script can be made more dynamic by using prompt to ask for a specific FLAT_FILE name but I leave that to you. What is does is that you first need to create a list with property names which you have to lookup first in the documentation. But then after placing those into your script you have a summary of all properties. See below script for an example.</p>
<p><code>set ff_prop_list { DATA_FILE_NAME IS_DELIMITED CHARACTERSET RECORD_DELIMITER RECORD_LENGTH RECORD_TYPE_COLUMN_NUMBER RECORD_TYPE_START_POSITION RECORD_TYPE_END_POSITION NUMBER_OF_RECORDS_TO_SKIP FIELD_DELIMITER FIELD_LEFT_ENCLOSURE NUMBER_OF_PHYSICAL_RECORDS_PER_LOGICAL CONTINUE_IF_ENDS_WITH CONTINUE_IF_STARTS_WITH }</p>
<p>set record_prop_list { RECORD_TYPE_VALUE }</p>
<p>set field_prop_list { DATATYPE LENGTH PRECISION SCALE START_POSITION SQL_DATATYPE SQL_LENGTH SQL_PRECISION SQL_SCALE MASK NULL_IF DEFAULT_IF }</p>
<p>foreach ff_prop $ff_prop_list {<br />
 set v_result  [ OMBRETRIEVE FLAT_FILE 'T999_KODE_DEF_TXT' GET PROPERTIES($ff_prop) ];<br />
 puts -nonewline "Flat File property: $ff_prop is: $v_result \n"<br />
}</p>
<p>foreach record_prop $record_prop_list {<br />
 set v_result  [ OMBRETRIEVE FLAT_FILE 'T999_KODE_DEF_TXT' RECORD 'T999_KODE_DEF_TXT' GET PROPERTIES($record_prop) ];<br />
 puts -nonewline "Record property: $record_prop is: $v_result \n"<br />
}</p>
<p>set field_list [ OMBRETRIEVE FLAT_FILE 'T999_KODE_DEF_TXT' RECORD 'T999_KODE_DEF_TXT' GET FIELDS ]</p>
<p>foreach field $field_list {<br />
puts "\n==== Field Properties of FIELD: $field ==== \n"<br />
foreach field_prop $field_prop_list {<br />
 set v_result  [ OMBRETRIEVE FLAT_FILE 'T999_KODE_DEF_TXT' RECORD 'T999_KODE_DEF_TXT' FIELD '$field' GET PROPERTIES($field_prop) ];<br />
 puts -nonewline "Field property: $field_prop is: $v_result \n"<br />
}<br />
}</code></p>
<p>Regards, Ilona</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Fred Haeckl</title>
		<link>http://www.it-eye.nl/weblog/2006/04/13/ombplus-create-mapping-with-operators/comment-page-1/#comment-20153</link>
		<dc:creator>Fred Haeckl</dc:creator>
		<pubDate>Fri, 08 Dec 2006 04:55:33 +0000</pubDate>
		<guid isPermaLink="false">http://www.it-eye.nl/weblog/?p=154#comment-20153</guid>
		<description>Ilona and Sjoerd,

Great information. I&#039;ve been working with OMBPlus for a while and would like to ask either one of you, do you have a good list of properties for each operator (or an object model for OMBPlus)?
OMBLIST gives you down to the ATTRIBUTE level, but then you have to GET PROPERTIES() by specific name. It doesn&#039;t seem to be in a list that .tcl can take advantage through via foreach syntax

The documentation is a bit cryptic and I stumbled on a property in FLAT_FILE OPERATOR that is not referenced in the help - I think it was START_POS or something like that. I&#039;m on a computer that doesn&#039;t have OWB installed right now. I found it in the property window of OWB MAPPING, but when I looked in OMBPlus documentation, it was not there.

Any help would be appreciated.

Thanks, Fred</description>
		<content:encoded><![CDATA[<p>Ilona and Sjoerd,</p>
<p>Great information. I&#8217;ve been working with OMBPlus for a while and would like to ask either one of you, do you have a good list of properties for each operator (or an object model for OMBPlus)?<br />
OMBLIST gives you down to the ATTRIBUTE level, but then you have to GET PROPERTIES() by specific name. It doesn&#8217;t seem to be in a list that .tcl can take advantage through via foreach syntax</p>
<p>The documentation is a bit cryptic and I stumbled on a property in FLAT_FILE OPERATOR that is not referenced in the help &#8211; I think it was START_POS or something like that. I&#8217;m on a computer that doesn&#8217;t have OWB installed right now. I found it in the property window of OWB MAPPING, but when I looked in OMBPlus documentation, it was not there.</p>
<p>Any help would be appreciated.</p>
<p>Thanks, Fred</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Ilona Tielke</title>
		<link>http://www.it-eye.nl/weblog/2006/04/13/ombplus-create-mapping-with-operators/comment-page-1/#comment-1464</link>
		<dc:creator>Ilona Tielke</dc:creator>
		<pubDate>Thu, 20 Apr 2006 21:27:36 +0000</pubDate>
		<guid isPermaLink="false">http://www.it-eye.nl/weblog/?p=154#comment-1464</guid>
		<description>Hi Sjoerd,
 
Thanks for your update. In the meanwhile we enhanched the code for creating mappings by adding a preprocess mapping operator to them. 

So, here&#039;s the code to that needs to be added to the code above.

ADD PREMAPPING_PROCESS OPERATOR &#039;PREM_TRUNCATE_TARGET&#039;  \
  SET PROPERTIES ( MAPPING_RUN_CONDITION, ROWBASED_ONLY ) \
  VALUES ( &#039;ON SUCCESS&#039;, 1 ) \
  BOUND TO PROCEDURE &#039;TRUNCATE_TARGET_TABLES&#039; 

Regards, Ilona</description>
		<content:encoded><![CDATA[<p>Hi Sjoerd,</p>
<p>Thanks for your update. In the meanwhile we enhanched the code for creating mappings by adding a preprocess mapping operator to them. </p>
<p>So, here&#8217;s the code to that needs to be added to the code above.</p>
<p>ADD PREMAPPING_PROCESS OPERATOR &#8216;PREM_TRUNCATE_TARGET&#8217;  \<br />
  SET PROPERTIES ( MAPPING_RUN_CONDITION, ROWBASED_ONLY ) \<br />
  VALUES ( &#8216;ON SUCCESS&#8217;, 1 ) \<br />
  BOUND TO PROCEDURE &#8216;TRUNCATE_TARGET_TABLES&#8217; </p>
<p>Regards, Ilona</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Sjoerd Evers</title>
		<link>http://www.it-eye.nl/weblog/2006/04/13/ombplus-create-mapping-with-operators/comment-page-1/#comment-1456</link>
		<dc:creator>Sjoerd Evers</dc:creator>
		<pubDate>Thu, 20 Apr 2006 17:28:43 +0000</pubDate>
		<guid isPermaLink="false">http://www.it-eye.nl/weblog/?p=154#comment-1456</guid>
		<description>Nice script that you made in OMBplus. I would like to fill you in on some extra information that you probably already know, but for the other readers of this weblog. For instance the targettables you making with :

ADD TABLE OPERATOR &#039;A_$sourceTableName\_CUM&#039; \
              BOUND TO TABLE &#039;../$sourcemodule/$sourceTableName\_CUM&#039; \

, could be expended with setting the properties for the loading type, i.e.

ADD TABLE OPERATOR &#039;U_$sourceTableName&#039; \
SET PROPERTIES ( LOADING_TYPE ) VALUES ( &#039;INSERT&#039; )
              BOUND TO TABLE &#039;$sourceTableName&#039; \

would be the default set to insert but if you would like to change it, this can be set to &#039;UPDATE&#039; (not that you want it in this case. Other loadingtype values are possible but it&#039;s tricky because they arent all supported. I dont have OMB running here atm but i do remember i have had problems with setting &#039;UPDATE/INSERT&#039; via OMBplus. This isn&#039;t an issue with this delta mapping because you would like to have all values set to &#039;INSERT&#039;, but does get more interesting in building skeleton mapping for the &#039;DWH&#039;layer where &#039;UPDATE/INSERT&#039; are no uncommon values.

If you would like to fit in some more text over where it says &#039;mapping comment&#039;, its possible to put down there a local variable and declare it before the actual OMBCREATE:

    OMBCREATE MAPPING &#039;E_$sourceTableName&#039; SET PROPERTIES (DESCRIPTION ) \
                                         VALUES (&#039;mapping comment&#039;) \

would become before OMBCREATE:


set nameit     &quot;--------------------------------------------------------------\n&quot;
append nameit  &quot; Mapping : E_$sourceTableName  \n&quot;
append nameit  &quot; Developer : by script \n&quot;
append nameit  &quot;-Version-----------------------------------------------------\n&quot;
append nameit  &quot; Date        Who    Why\n&quot;
append nameit  &quot;-End---------------------------------------------------------\n&quot;

(then:)

    OMBCREATE MAPPING &#039;E_$sourceTableName&#039; SET PROPERTIES (DESCRIPTION ) \
                                         VALUES (&#039;$nameit&#039;) \</description>
		<content:encoded><![CDATA[<p>Nice script that you made in OMBplus. I would like to fill you in on some extra information that you probably already know, but for the other readers of this weblog. For instance the targettables you making with :</p>
<p>ADD TABLE OPERATOR &#8216;A_$sourceTableName\_CUM&#8217; \<br />
              BOUND TO TABLE &#8216;../$sourcemodule/$sourceTableName\_CUM&#8217; \</p>
<p>, could be expended with setting the properties for the loading type, i.e.</p>
<p>ADD TABLE OPERATOR &#8216;U_$sourceTableName&#8217; \<br />
SET PROPERTIES ( LOADING_TYPE ) VALUES ( &#8216;INSERT&#8217; )<br />
              BOUND TO TABLE &#8216;$sourceTableName&#8217; \</p>
<p>would be the default set to insert but if you would like to change it, this can be set to &#8216;UPDATE&#8217; (not that you want it in this case. Other loadingtype values are possible but it&#8217;s tricky because they arent all supported. I dont have OMB running here atm but i do remember i have had problems with setting &#8216;UPDATE/INSERT&#8217; via OMBplus. This isn&#8217;t an issue with this delta mapping because you would like to have all values set to &#8216;INSERT&#8217;, but does get more interesting in building skeleton mapping for the &#8216;DWH&#8217;layer where &#8216;UPDATE/INSERT&#8217; are no uncommon values.</p>
<p>If you would like to fit in some more text over where it says &#8216;mapping comment&#8217;, its possible to put down there a local variable and declare it before the actual OMBCREATE:</p>
<p>    OMBCREATE MAPPING &#8216;E_$sourceTableName&#8217; SET PROPERTIES (DESCRIPTION ) \<br />
                                         VALUES (&#8216;mapping comment&#8217;) \</p>
<p>would become before OMBCREATE:</p>
<p>set nameit     &#8220;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8211;\n&#8221;<br />
append nameit  &#8221; Mapping : E_$sourceTableName  \n&#8221;<br />
append nameit  &#8221; Developer : by script \n&#8221;<br />
append nameit  &#8220;-Version&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8211;\n&#8221;<br />
append nameit  &#8221; Date        Who    Why\n&#8221;<br />
append nameit  &#8220;-End&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;\n&#8221;</p>
<p>(then:)</p>
<p>    OMBCREATE MAPPING &#8216;E_$sourceTableName&#8217; SET PROPERTIES (DESCRIPTION ) \<br />
                                         VALUES (&#8216;$nameit&#8217;) \</p>
]]></content:encoded>
	</item>
</channel>
</rss>
