Focal Point Banner


As of December 1, 2020, Focal Point is retired and repurposed as a reference repository. We value the wealth of knowledge that's been shared here over the years. You'll continue to have access to this treasure trove of knowledge, for search purposes only. Moving forward, myibi is our community platform to learn, share, and collaborate. We have the same Focal Point forum categories in myibi, so you can continue to have all new conversations there. If you need access to myibi, contact us at myibi@ibi.com and provide your corporate email address, company, and name.


Connect to myibi
Focal Point    Focal Point Forums  Hop To Forum Categories  iWay Software Product Forum on Focal Point    [SOLVED] DMC - mapping Datefield with SQL GetDate

Read-Only Read-Only Topic
Go
Search
Notify
Tools
[SOLVED] DMC - mapping Datefield with SQL GetDate
 Login/Join
 
Member
posted
Hi,

I want to pass sql expression into my query.

Moving data from source to Destination. Want to pass EditDate as Getdate(). Which will be date from sql server. Is there any way to make it recognize GetDate. I tried adding transform and and seeing SELECt query, its saying its invalid.

Please let me know if its possible

Thank
D

This message has been edited. Last edited by: FP Mod Chuck,


WebFOCUS 8
Windows, All Outputs
 
Posts: 16 | Registered: July 15, 2016Report This Post
Guru
posted Hide Post
The SQL Server function GETDATE() actually returns the current date and time to the millisecond.

You can get the current timestamp with the function
CURRENT_TIMESTAMP(3) 

However the milliseconds are zeroed out.

So if you need that precision or for some other reason need to use GETDATE() assuming the source table(s) are in MS SQL Server you can invoke a Transact SQL function or expression like this:
DB_EXPR(GETDATE())  


N/A
 
Posts: 397 | Location: New York City | Registered: May 03, 2007Report This Post
Member
posted Hide Post
Hi Thank you for reply. I tried DB_EXPR(GETDAET()) at multiple places its not recognizing the syntax.

Where should this be valid to do. In Select object, Target Object mapping or source Object mapping. Its not taking it. If you have done so incase can you please share screenshot?

Thanks
D


WebFOCUS 8
Windows, All Outputs
 
Posts: 16 | Registered: July 15, 2016Report This Post
Guru
posted Hide Post
In the SQL object under SQL Expression works. BTW there's a typo in your post. Make sure you spell the function name correctly.


N/A
 
Posts: 397 | Location: New York City | Registered: May 03, 2007Report This Post
  Powered by Social Strata  

Read-Only Read-Only Topic

Focal Point    Focal Point Forums  Hop To Forum Categories  iWay Software Product Forum on Focal Point    [SOLVED] DMC - mapping Datefield with SQL GetDate

Copyright © 1996-2020 Information Builders