# ToJulianDayNumber (DateTime)

| **Name**    | ***ToJulianDayNumber***                                                                                                                          |
| ----------- | ------------------------------------------------------------------------------------------------------------------------------------------------ |
| Syntax      | ToJulianDayNumber (Date dateTime)                                                                                                                |
| Purpose     | To convert a date to a Julian day number.                                                                                                        |
| Description | Returns an integer representing Julian day number for the specified date time. This function discards the time component of the date time value. |
| Return Type | Int64                                                                                                                                            |
| Parameter   | dateTime \[System.DateTime] – DateTime object for which the Julian day number will be returned                                                   |

![](https://github.com/astera-software/Astera_Data_Stack_v9/blob/main/.gitbook/assets/0%20\(114\).png)

**Example**

In this example, we will pass a valid date time value to the function transformation object using a *Variables* object.

Where,

*dateTime* ­= 04/10/2020 10:10:25 AM

![](https://github.com/astera-software/Astera_Data_Stack_v9/blob/main/.gitbook/assets/1%20\(115\).png)

In the output window, you can see that the provided value has been converted into a Julian day number.

![](https://github.com/astera-software/Astera_Data_Stack_v9/blob/main/.gitbook/assets/2%20\(115\).png)
