Join our Community in its new Home - The Datorama Trailblazer Community Group!

It's been an amazing 3 years coming together in this forum to collaborate, innovate, support, and inspire each other about our shared usage of Datorama. While this is not quite a goodbye, we are excited to announce that we are getting a fresh start in our new home within the Salesforce Trailblazer Community. We have a ton of fun new content planned and you may even see the revival of some of our most popular posts from the past few years.

We’ll be keeping this group around for a bit for you to peruse, but as of November 15, we will no longer be allowing new posts or comments. Be sure to join our new group at https://www.salesforce.com/success-datorama to keep the conversation going.

We can’t wait to see you there!

Manipulating the date format of a data stream

Comments

  • anitaanita SingaporeSYS_ADMIN IMG42
    Hey @Ashleigh_F1sher ,

    Good day! You can definitely manipulate your data to take certain part of the csv['Date'] value. In your example if your value is 2019-01-18 (Fri), you can extract "2019-01-18" using EXTRACT function, and then getting the system to read the format by PARSEDATE function.

    Eg:
    var d = TRIM(EXTRACT(csv['Date'],"(",0));
    PARSEDATE (d,"YYYY-MM-dd");

    Let us know if this helps. Your CSM can also advise you further if you are seeing other date format :)

  • anitaanita SingaporeSYS_ADMIN IMG42
    Hi @Mareets, there are a few ways to extract the date in the format you mentioned, one way is to use the LEFT() function to get the first 10 char then parse it, eg:

    var d = LEFT(csv['campaign2'],10);
    PARSEDATE (d,"YYYY-MM-dd");

    It would be best to also raise a ticket and attach your sample file, also indicating which data stream and account you are trying this on.

    All the best!
  • anitaanita SingaporeSYS_ADMIN IMG42
    HI @Mareets, FORMATDATE_DEFAULT(your field) can change any format to a default format , ref:
    https://support.datorama.com/en/support/solutions/articles/4000139660-formulas-in-datorama

    From there you can extract the portion you need.

    If you still need more assistance, it would be best to send in your ticket to [email protected] and also attach your sample file. Please mention the workspace and data stream ID too, so we can look into your current setup.
    Thanks.


Sign In or Register to comment.