lucene-solr-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ashokc <ash...@qualcomm.com>
Subject Re: Oracle Clob column with DIH does not turn to String
Date Fri, 03 Apr 2009 19:28:31 GMT

Happy to report that it is working. Looks like we have to use UPPER CASE for
all the column names. When I examined the map 'aRow', it had the column
names in upper case, where as my config had lower case. No match was found
so nothing happened. Changed my config and it works now. Thanks for your
help. Perhaps this transformer can be modified to be case-insensitive for
the column names. If you had written it perhaps it is a quick change for
you? 

Noble Paul നോബിള്‍  नोब्ळ् wrote:
> 
> I guess u can write a custom transformer which gets a String out of
> the oracle.sql.CLOB. I am just out of clue, why this may happen. I
> even wrote a testcase and it seems to work fine
> --Noble
> 
> On Fri, Apr 3, 2009 at 10:23 PM, ashokc <ashokc@qualcomm.com> wrote:
>>
>> I downloaded the nightly build yesterday (2nd April), modified the
>> ClobTransformer.java file with some prints, compiled it all (ant dist).
>> It
>> produced a war file, "apache-solr-1.4-dev.war". That is what I am using.
>> My
>> modification & compilation has not affected the results. I was getting
>> the
>> same behavior with the 'war' that download came with. Thanks Noble.
>>
>> Noble Paul നോബിള്‍  नोब्ळ् wrote:
>>>
>>> and which version of Solr are u using?
>>>
>>> On Fri, Apr 3, 2009 at 10:09 PM, ashokc <ashokc@qualcomm.com> wrote:
>>>>
>>>> Sure:
>>>>
>>>> data-config Xml
>>>> ===============
>>>>
>>>> <dataConfig>
>>>>    <dataSource driver="oracle.jdbc.driver.OracleDriver"
>>>> url="jdbc:oracle:thin:@xxxxx" user="remedy" password="yyyyy"/>
>>>>    <document name="remedy">
>>>>            <entity name="log" transformer="ClobTransformer"
>>>> query="SELECT
>>>> mylog_ato, name_char, dsc FROM log_tbl">
>>>>                <field column="mylog_ato" name="log_no" />
>>>>                <field column="name_char" name="short_desc" />
>>>>                <field column="dsc" clob="true" name="description"
/>
>>>>            </entity>
>>>>    </document>
>>>> </dataConfig>
>>>>
>>>> ===========
>>>>
>>>> A search result on the field short_desc:
>>>> --------------------------------------
>>>>
>>>> <doc>
>>>> <float name="score">1.8670129</float>
>>>> <str name="description">oracle.sql.CLOB@155e3ab</str>
>>>> <int name="log_no">4486</int>
>>>> <str name="short_desc">Develop Rating functionality for QIN</str>
>>>> <date name="timestamp">2009-04-03T11:47:32.635Z</date>
>>>> </doc>
>>>>
>>>>
>>>>
>>>>
>>>> Noble Paul നോബിള്‍  नोब्ळ् wrote:
>>>>>
>>>>> There is something else wrong with your setup.
>>>>>
>>>>> can you just paste the whole data-config.xml
>>>>>
>>>>> --Noble
>>>>>
>>>>> On Fri, Apr 3, 2009 at 5:39 PM, ashokc <ashokc@qualcomm.com> wrote:
>>>>>>
>>>>>> Noble,
>>>>>> I put in a few 'System.out.println' statements in the
>>>>>> ClobTransformer.java
>>>>>> file & remade the war. But I see none of these prints coming
up in my
>>>>>> 'catalina.out' file. Is that the right file to be looking at?
>>>>>>
>>>>>> As an aside, is 'catalina.out' the ONLY log file for SOLR? I turned
>>>>>> on
>>>>>> the
>>>>>> logging to 'FINE' for everything. Also, these settings seem to go
>>>>>> away
>>>>>> when
>>>>>> Tomcat is restarted.
>>>>>> - ashok
>>>>>>
>>>>>> Noble Paul നോബിള്‍  नोब्ळ् wrote:
>>>>>>>
>>>>>>> yeah, ant dist will give you the .war file you may need . just
drop
>>>>>>> it
>>>>>>> in and you are set to go. or if you can hook up a debugger to
a
>>>>>>> running Solr that is the easiest
>>>>>>> --Noble
>>>>>>>
>>>>>>> On Fri, Apr 3, 2009 at 9:35 AM, ashokc <ashokc@qualcomm.com>
wrote:
>>>>>>>>
>>>>>>>> That would require me to recompile (with ant/maven scripts?)
the
>>>>>>>> source
>>>>>>>> and
>>>>>>>> replace the jar for DIH, right? I can try - for the first
time.
>>>>>>>> - ashok
>>>>>>>>
>>>>>>>> Noble Paul നോബിള്‍  नोब्ळ् wrote:
>>>>>>>>>
>>>>>>>>> This looks strange. Apparently the Transformer did not
get
>>>>>>>>> applied.
>>>>>>>>> Is
>>>>>>>>> it possible for you to debug ClobTransformer
>>>>>>>>> adding(System.out.println
>>>>>>>>> into ClobTransformer may help)
>>>>>>>>>
>>>>>>>>> On Fri, Apr 3, 2009 at 6:04 AM, ashokc <ashokc@qualcomm.com>
>>>>>>>>> wrote:
>>>>>>>>>>
>>>>>>>>>> Correcting my earlier post. It lost some lines some
how.
>>>>>>>>>>
>>>>>>>>>> Hi,
>>>>>>>>>>
>>>>>>>>>> I have set up to import some oracle clob columns
with DIH. I am
>>>>>>>>>> using
>>>>>>>>>> the
>>>>>>>>>> latest nightly release. My config says,
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> <entity name="log" transformer="ClobTransformer"
>>>>>>>>>> ...
>>>>>>>>>>
>>>>>>>>>>    <field column="description" clob="true" name="description"
/>
>>>>>>>>>>    ....
>>>>>>>>>>
>>>>>>>>>> </entity>
>>>>>>>>>>
>>>>>>>>>> But it does not seem to turn this clob into a String.
The search
>>>>>>>>>> results
>>>>>>>>>> show:
>>>>>>>>>>
>>>>>>>>>> <doc>
>>>>>>>>>>   <float name="score">1.8670129</float>
>>>>>>>>>>    <str name="description">oracle.sql.CLOB@aed3a5</str>
>>>>>>>>>>   <int name="log_no">4486</int>
>>>>>>>>>> </doc>
>>>>>>>>>>
>>>>>>>>>> Any pointers on why I do not get the 'string' out
of the clob for
>>>>>>>>>> indexing?
>>>>>>>>>> Is the nightly war NOT the right one to use?
>>>>>>>>>>
>>>>>>>>>> Thanks for your help.
>>>>>>>>>>
>>>>>>>>>> - ashok
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> ashokc wrote:
>>>>>>>>>>>
>>>>>>>>>>> Hi,
>>>>>>>>>>>
>>>>>>>>>>> I have set up to import some oracle clob columns
with DIH. I am
>>>>>>>>>>> using
>>>>>>>>>>> the
>>>>>>>>>>> latest nightly release. My config says,
>>>>>>>>>>>
>>>>>>>>>>> <entity name="description" transformer="ClobTransformer"
...
>>>>>>>>>>> <field
>>>>>>>>>>> column="description" clob="true" />
>>>>>>>>>>>     ....
>>>>>>>>>>>
>>>>>>>>>>> </entity>
>>>>>>>>>>>
>>>>>>>>>>> But it does not seem to turn this clob into a
String. The search
>>>>>>>>>>> results
>>>>>>>>>>> show:
>>>>>>>>>>>
>>>>>>>>>>> <doc>
>>>>>>>>>>>    <float name="score">1.8670129</float>
>>>>>>>>>>>     <str name="description">oracle.sql.CLOB@aed3a5</str>
>>>>>>>>>>>    <int name="log_no">4486</int>
>>>>>>>>>>> </doc>
>>>>>>>>>>>
>>>>>>>>>>> Any pointers on why I do not get the 'string'
out of the clob
>>>>>>>>>>> for
>>>>>>>>>>> indexing? Is the nightly war NOT the right one
to use?
>>>>>>>>>>>
>>>>>>>>>>> Thanks for your help.
>>>>>>>>>>>
>>>>>>>>>>> - ashok
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> --
>>>>>>>>>> View this message in context:
>>>>>>>>>> http://www.nabble.com/Oracle-Clob-column-with-DIH-does-not-turn-to-String-tp22859837p22859865.html
>>>>>>>>>> Sent from the Solr - User mailing list archive at
Nabble.com.
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> --
>>>>>>>>> --Noble Paul
>>>>>>>>>
>>>>>>>>>
>>>>>>>>
>>>>>>>> --
>>>>>>>> View this message in context:
>>>>>>>> http://www.nabble.com/Oracle-Clob-column-with-DIH-does-not-turn-to-String-tp22859837p22861630.html
>>>>>>>> Sent from the Solr - User mailing list archive at Nabble.com.
>>>>>>>>
>>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> --
>>>>>>> --Noble Paul
>>>>>>>
>>>>>>>
>>>>>>
>>>>>> --
>>>>>> View this message in context:
>>>>>> http://www.nabble.com/Oracle-Clob-column-with-DIH-does-not-turn-to-String-tp22859837p22867161.html
>>>>>> Sent from the Solr - User mailing list archive at Nabble.com.
>>>>>>
>>>>>>
>>>>>
>>>>>
>>>>>
>>>>> --
>>>>> --Noble Paul
>>>>>
>>>>>
>>>>
>>>> --
>>>> View this message in context:
>>>> http://www.nabble.com/Oracle-Clob-column-with-DIH-does-not-turn-to-String-tp22859837p22872184.html
>>>> Sent from the Solr - User mailing list archive at Nabble.com.
>>>>
>>>>
>>>
>>>
>>>
>>> --
>>> --Noble Paul
>>>
>>>
>>
>> --
>> View this message in context:
>> http://www.nabble.com/Oracle-Clob-column-with-DIH-does-not-turn-to-String-tp22859837p22872440.html
>> Sent from the Solr - User mailing list archive at Nabble.com.
>>
>>
> 
> 
> 
> -- 
> --Noble Paul
> 
> 

-- 
View this message in context: http://www.nabble.com/Oracle-Clob-column-with-DIH-does-not-turn-to-String-tp22859837p22874217.html
Sent from the Solr - User mailing list archive at Nabble.com.


Mime
View raw message