DATA Step, Macro, Functions and more

problem in date function

Accepted Solution Solved
Reply
Contributor
Posts: 27
Accepted Solution

problem in date function

Hello everyone,

I have two variables for dates i.e. start date and stop date (along with time format) . To skip time, we are using trunc function. when I used the same , I got error like

ERROR: Function TRUNC requires at least 2 argument(s).

Can anyone help me  as I am new.

trunc(stop_date) >trunc(start_date)

when I used datepart function , i got error like

NOTE: Invalid (or missing) arguments to the DATEPART function have caused the function to return a missing value.


Accepted Solutions
Solution
‎08-30-2012 08:28 AM
Super Contributor
Posts: 1,636

Re: problem in date function

You should use datepart function. the error message may be caused by missing stop_date or start_date.

View solution in original post


All Replies
Solution
‎08-30-2012 08:28 AM
Super Contributor
Posts: 1,636

Re: problem in date function

You should use datepart function. the error message may be caused by missing stop_date or start_date.

🔒 This topic is solved and locked.

Need further help from the community? Please ask a new question.

Discussion stats
  • 1 reply
  • 1132 views
  • 0 likes
  • 2 in conversation