Quantcast
Channel: Mockaroo Community Forum - Latest posts
Viewing all articles
Browse latest Browse all 2665

Date format changes when using formula

$
0
0

Hey everyone,

I need to generate some data to import on a mongoDB database.
There is a nice date field in mockaroo called MongoDB Iso.
And it returns the date in the format i want for example: "mongo_date": "$date":"2017-06-06T00:00:00.000Z"

However when i write something in the formula like "this + hours(12)"

The format changes to something default: "mongo_date": "2017-06-06 01:00:00 UTC",

But i want the nested $date tag with it like above. ( "mongo_date": "$date":"2017-06-06T00:00:00.000Z")

The result i want:

  • "mongo_date": "$date":"2017-06-06T00:00:00.000Z"

The result i get:

"mongo_date": "2017-06-06 00:00:00 UTC"

So how do i get the result i want? While still being able to use a formula on a date field.

My schema: https://www.mockaroo.com/742734f0


Viewing all articles
Browse latest Browse all 2665

Trending Articles