Best answer

Need help splitting the date MM/DD/YYYY to separate fields

  • 6 January 2022
  • 6 replies
  • 554 views

  • Anonymous
  • 0 replies

So I’m ultimately trying to separate as a field the year that my zap runs so that i can do other stuff with it but i’m stuck after having formatted it to MM/DD/YYYY.

I first tried to use a custom format in the Formatter but that didn’t work as Zapier would only let me search for fields in the custom section.

So then I tried to use the split text Transform in the  Formatter but I can’t seem to nail the Separator to tell Zapier to split by by the forward slash.  The article underneath the Separator just hands less than handful of options.

Any help would be greatly appreciated.

icon

Best answer by Anonymous 6 January 2022, 03:07

View original

This post has been closed for comments. Please create a new post if you need help or have a question about this topic.

6 replies

Userlevel 7
Badge +14

Hi @ZaptheNewb 

Try this:

 

OUTPUT

 

Thanks @Troy Tessalone but that yields this.

 

 

Could it then have to do with the input? … which is just an output of this.

 

 

 

Userlevel 7
Badge +14

@ZaptheNewb 

I used the Formatter > Text > Split option to separate a Date into DD, MM, YYYY fields.

Userlevel 7
Badge +14

@ZaptheNewb 

Or if you just want YYYY from a date or timestamp try this:

 

OUTPUT

 

CONFIG

 

Thanks @Troy Tessalone !  I did exactly that… when I manually enter the text string it worked just as yours did in the first post.  However, when I add the Output of my response as the input in the Formatter > Text > Split Text that we’re talking about Zapier just returns the same input… so it must not recognize the Input from the other step as a text string or something.

Either way I got it to work with what I was trying to do earlier and just didn’t click through properly… here is what I did to return just the year of the current date of my zap.  Using Formatter > Date / Time > Format, with  {{zap_meta_pst_isc}} is the input and in the To Format field click on custom and then just click back on the To Format field so that the search bar goes away.  I know it seems very simple but it stomped me.  Maybe I just needed a break but it was enough to get me to sign up and make this post. 

Here’s what it looks like.

 

And here is the output.

 

Userlevel 1

Even me too I'm also facing these kind of issue with the site naijadiamond I'm very happy getting the solution from these thread. Thanks Zapier Team.