the deltaQuery select 'product_id' and your deltaImportQuery uses ${dataimporter.delta.id} I guess it should have been ${dataimporter.delta. product_id}
On Wed, Dec 2, 2009 at 11:52 PM, Thomas Woodard <gtfo...@hotmail.com> wrote: > > I'm trying to get delta indexing set up. My configuration allows a full index > no problem, but when I create a test delta of a single record, the delta > import finds the record but then does nothing. I can only assume I have > something subtly wrong with my configuration, but according to the wiki, my > configuration should be valid. What I am trying to do is have a single delta > detected on the top level entity trigger a rebuild of everything under that > entity, the same as the first example in the wiki. Any help would be greatly > appreciated. > > <dataConfig> > <dataSource name="prodcat" driver="oracle.jdbc.driver.OracleDriver" > url="jdbc:oracle:oci:@XXX" > user="XXX" password="XXX" autoCommit="false" > transactionIsolation="TRANSACTION_READ_COMMITTED"/> > > <document> > <entity name="product" dataSource="prodcat" query=" > select dp.product_id, dp.display_name, dp.long_description, > gp.orientation > from dcs_product dp, gl_product gp > where dp.product_id = gp.product_id" > transformer="ClobTransformer,HTMLStripTransformer" > deltaImportQuery="select dp.product_id, dp.display_name, > dp.long_description, gp.orientation > from dcs_product dp, gl_product gp > where dp.product_id = gp.product_id > AND dp.product_id = '${dataimporter.delta.id}'" > deltaQuery="select product_id from gl_product_modified where > last_modified > TO_DATE('${dataimporter.last_index_time}', 'yyyy-mm-dd > hh:mi:ss')" > rootEntity="false" > pk="PRODUCT_ID"> > <!-- COLUMN NAMES ARE CASE SENSITIVE. THEY NEED TO BE ALL CAPS OR > EVERYTHING FAILS --> > <field column="PRODUCT_ID" name="product_id"/> > <field column="DISPLAY_NAME" name="name"/> > <field column="LONG_DESCRIPTION" name="long_description" > clob="true" stripHTML="true" /> > <field column="ORIENTATION" name="orientation"/> > > <entity name="sku" dataSource="prodcat" query="select ds.sku_id, > ds.sku_type, ds.on_sale, '${product.PRODUCT_ID}' || '_' || ds.sku_id as > unique_id > from dcs_prd_chldsku dpc, dcs_sku ds > where dpc.product_id = '${product.PRODUCT_ID}' > and dpc.sku_id = ds.sku_id" > rootEntity="true" pk="PRODUCT_ID, SKU_ID"> > <field column="SKU_ID" name="sku_id"/> > <field column="SKU_TYPE" name="sku_type"/> > <field column="ON_SALE" name="on_sale"/> > <field column="UNIQUE_ID" name="unique_id"/> > > <entity name="catalog" dataSource="prodcat" query="select > pc.catalog_id > from gl_prd_catalog pc, gl_sku_catalog sc > where pc.product_id = '${product.PRODUCT_ID}' and > sc.sku_id = '${sku.SKU_ID}' and pc.catalog_id = sc.catalog_id" pk="SKU_ID, > CATALOG_ID"> > <field column="CATALOG_ID" name="catalogs"/> > </entity> > > <entity name="price" dataSource="prodcat" query="select > ds.list_price as price > from dcs_sku ds > where ds.sku_id = '${sku.SKU_ID}' > and ds.on_sale = 0 > UNION > select ds.sale_price as price > from dcs_sku ds > where ds.sku_id = '${sku.SKU_ID}' > and ds.on_sale = 1" > pk="SKU_ID"> > <field column="PRICE" name="price"/> > </entity> > </entity> > > <entity name="studio" dataSource="prodcat" query="select gs.name > from gl_product_studio gps, gl_studio gs where gps.studio_id = gs.studio_id > and gps.product_id = '${product.PRODUCT_ID}'" rootEntity="false" > pk="PRODUCT_ID"> > <field column="NAME" name="studio"/> > </entity> > > <entity name="star" dataSource="prodcat" query="select gc.name > from gl_contributor gc, gl_product_contributor gpc > where gc.contributor_id = gpc.contributor_id and > gpc.product_id = '${product.PRODUCT_ID}'" rootEntity="false" pk="PRODUCT_ID, > CONTRIBUTOR_ID"> > <field column="NAME" name="stars"/> > </entity> > > <entity name="director" dataSource="prodcat" query="select gc.name > from gl_contributor gc, gl_product_director gpd > where gc.contributor_id = gpd.contributor_id and > gpd.product_id = '${product.PRODUCT_ID}'" rootEntity="false" pk="PRODUCT_ID, > CONTRIBUTOR_ID"> > <field column="NAME" name="directors"/> > </entity> > > <entity name="keyword" dataSource="prodcat" query="select > dcs_category.display_name as keyword_name > from dcs_cat_chldprd, dcs_category, gl_category > where gl_category.availability = 0 > and gl_category.exclude_in_vivisimo = 0 > and dcs_category.category_id = gl_category.category_id > and dcs_cat_chldprd.category_id = > dcs_category.category_id > and dcs_cat_chldprd.child_prd_id = > '${product.PRODUCT_ID}' > union > select display_name as keyword_name > from gl_product_scene ps, gl_scene_tag st, gl_tag tag > where ps.scene_id = st.scene_id > and st.tag_id = tag.tag_id > and tag.type in (0,1) > and ps.product_id = '${product.PRODUCT_ID}' > union > select display_name as keyword_name > from gl_product_scene ps, gl_scene_tag st, gl_tag tag > where ps.scene_id = st.scene_id > and st.tag_id = tag.tag_id > and tag.type = 2 > and ps.product_id = '${product.PRODUCT_ID}'" > rootEntity="false" pk="PRODUCT_ID, KEYWORD_NAME"> > <field column="KEYWORD_NAME" name="keywords"/> > </entity> > </entity> > </document> > </dataConfig> > > > _________________________________________________________________ > Windows Live Hotmail gives you a free,exclusive gift. > http://www.microsoft.com/windows/windowslive/hotmail_bl1/hotmail_bl1.aspx?ocid=PID23879::T:WLMTAGL:ON:WL:en-ww:WM_IMHM_7:092009 -- ----------------------------------------------------- Noble Paul | Principal Engineer| AOL | http://aol.com