Uploaded image for project: 'Sqoop (Retired)'
  1. Sqoop (Retired)
  2. SQOOP-2767

Test is failing SystemImportTest

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Major
    • Resolution: Fixed
    • 1.4.6
    • 1.4.7
    • None
    • None

    Description

      I've noticed that SystemImportTest is constantly failing in my environment. I've dig into the problem and I've noticed that we're no longer able to import URITYPE from Oracle (it's always imported as NULL.

      The test started failing after we made changes back in SQOOP-2723 - the generated select queries has changed from:

      SELECT /*+ NO_INDEX(t) */ ID,BD,BF,B,C,CL,D,F,L,NC,NCL,N,NVC,R,uritype.geturl(U),IYM,IDS,T,TZ,TLTZ,RAWCOL,'6_2' data_chunk_id FROM oraoop_test t WHERE
      

      To something like:

      SELECT /*+ NO_INDEX(t) */ "ID","BD","BF","B","C","CL","D","F","L","NC","NCL","N","NVC","R","U","IYM","IDS","T","TZ","TLTZ","RAWCOL",'6_1' data_chunk_id FROM oraoop_test  t WHERE 
      

      Notice how the column U is selected as uritype.getUrl() in first example and as simple U in the second one. The problem is that we're doing special magic based on type in OraOopDBRecordReader. The reason why this magic got broken is that we're building a list of all columns with types from the database and then searching for each individual column during select query generation. However the list contains unescaped columns whereas the "work column" is escaped. Hence the find here always fails.

      Attachments

        1. SQOOP-2767.patch
          1.0 kB
          Jarek Jarcec Cecho

        Activity

          People

            jarcec Jarek Jarcec Cecho
            jarcec Jarek Jarcec Cecho
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: