If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

 
Go Back  dBforums > Database Server Software > Oracle > ssis expression (oracle databae)

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old 01-10-12, 15:05
h.singh10 h.singh10 is offline
Registered User
 
Join Date: Dec 2011
Posts: 13
ssis expression (oracle databae)

Hi

I am putting the below query in a OLEDB SOURCE through a variable (it is a select statement with a where clause from one date to another).

I am getting through this expression. Can you have a check on it please.I dont know whats is wrong with this expression


"select TestRecordtype, request_id from department

where LOAD_TMSTP between
(select max(END_TMSTP) LOG) and
(TO_DATE("+RIGHT("0" + (DT_STR,4,1252)DATEPART( "dd" , @[System:tartTime] ), 2) + "-"
+RIGHT("0" + (DT_STR,4,1252)DATEPART( "mm" , @[System:tartTime] ), 2) + "-"
+RIGHT("0" + (DT_STR,4,1252)DATEPART( "yy" , @[System:tartTime] ), 2) + " "
+RIGHT("0" + (DT_STR,4,1252)DATEPART( "hh" , @[System:tartTime] ), 2) + "."
+RIGHT("0" + (DT_STR,4,1252)DATEPART( "mi" , @[System:tartTime] ), 2) + "."
+RIGHT("0" + (DT_STR,4,1252)DATEPART( "ss" , @[System:tartTime] ), 2) +",'DD-MM-YY HH24.MI.SS')) "

Thanks
Reply With Quote
  #2 (permalink)  
Old 01-10-12, 15:41
LKBrwn_DBA LKBrwn_DBA is offline
Registered User
 
Join Date: Jun 2003
Location: West Palm Beach, FL
Posts: 2,456
Cool

Quote:
Originally Posted by h.singh10 View Post
... Etc ...
... Can you have a check on it please.I dont know whats is wrong with this expression
If it's meant to be an "Oracle" sql query, It's not! Incorrect (non Oracle) syntax.
__________________
The person who says it can't be done should not interrupt the person doing it. -- Chinese proverb
Reply With Quote
  #3 (permalink)  
Old 01-10-12, 15:43
anacedent anacedent is offline
Registered User
 
Join Date: Aug 2003
Location: Where the Surf Meets the Turf @Del Mar, CA
Posts: 6,416
I do not recognize it as being valid to Oracle RDBMS.

>System:tartTime
Looks strange to me.
should it be "SystemtartTime" instead?
__________________
You can lead some folks to knowledge, but you can not make them think.
The average person thinks he's above average!
For most folks, they don't know, what they don't know.
Reply With Quote
  #4 (permalink)  
Old 01-10-12, 16:33
h.singh10 h.singh10 is offline
Registered User
 
Join Date: Dec 2011
Posts: 13
yes it is start time.
I dont know how it gets misstyped
Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On