Uploaded image for project: 'Sqoop'
  1. Sqoop
  2. SQOOP-3082

Sqoop import fails after TCP connection reset if split by datetime column

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 1.4.6
    • Fix Version/s: 1.5.0
    • Component/s: None
    • Labels:
      None

      Description

      If sqoop-to-mssqlserver connection reset, the whole command fails with "Connection reset with com.microsoft.sqlserver.jdbc.SQLServerException: Incorrect syntax near '00'" . On reestablishing connection, Sqoop tries to resume import from the last record that was successfully read by :

      2016-12-10 15:18:54,523 INFO [main] org.apache.sqoop.mapreduce.db.DBRecordReader: Executing query: select * from test.dbo.test1 WITH (nolock) where Date >= '2015-01-10' and Date <= '2016-11-24' and ( Date > 2015-09-18 00:00:00.0 ) AND ( Date < '2015-09-23 11:48:00.0' ) 
      

      Not quoted 2015-09-18 00:00:00.0 in SQL.

        Attachments

        1. SQOOP-3082.patch
          0.8 kB
          Sergey Svynarchuk
        2. SQOOP-3082-1.patch
          0.8 kB
          Fero Szabo

          Issue Links

            Activity

              People

              • Assignee:
                Unassigned
                Reporter:
                vaifer Sergey Svynarchuk
              • Votes:
                0 Vote for this issue
                Watchers:
                6 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: