2016-07-25 3 views
0

오라클 테이블에서 데이터를 가져 와서 SQL 서버로 푸시하는 간단한 작업이 있습니다. 오라클 날짜가있는 SSIS 식 작성기

쿼리를 저장하는 변수를 생성하고 표현식 빌더에서이 제공 :

 select col1,col2,col3,col4 
     from <schema>.table 
     WHERE closedate between to_date('" + (DT_WSTR,10) @[User::ReportStartDate]+"','YYYY-MM-DD') and to_date('" + (DT_WSTR,10) @[User::ReportEndDate] + "','YYYY-MM-DD') 

    However, when evaluating the expression, it fails with the message: "The expression might contain an invalid token, an incomplete token or an invalid element. It might not be well-formed or might be missing part of the required element such as paranthesis" 

지금 꽤 많은 시간 동안 그것을 찾고 있지만, 분명 아무것도 찾을 수 없습니다. 여기서 내가 뭘 잘못하고 있니?

TIA, 꿀벌

+0

정말 완전한 표현입니까? 처음과 마지막에 큰 따옴표가 누락 된 것 같습니다. – onupdatecascade

답변

0

추가 시작과 표현이
"select col1,col2,col3,col4 from <schema>.table WHERE closedate between to_date('" + (DT_WSTR,10) @[User::ReportStartDate]+"','YYYY-MM-DD') and to_date('" + (DT_WSTR,10) @[User::ReportEndDate] + "','YYYY-MM-DD')"
로 전환하고 유효한 문자열을 산출 오류없이 평가 있도록 따옴표를 종료.

+0

완벽합니다. 대단히 감사합니다. @Ferdipux. 따옴표가 도움이되었습니다. – Bee

관련 문제