0

I'm working on a project where I need to pull person details from an endpoint. There is a field called 'birthday' that is a number that looks like something like this: 558289857 Any idea what form this is and how I can convert that to a date?

RunFranks525
  • 163
  • 1
  • 2
  • 14

1 Answers1

0
long birthDateLong = Long.parseLong(inputMap.get("birthday")); //Assuming a string
Date birthDay = new Date(birthDateLong);
//This gives you, for your example (558289857), Wed Jan 07 13:04:49 SAST 1970. Perhaps only the date and month are meanto to be meaningful? Check your data.
ernest_k
  • 44,416
  • 5
  • 53
  • 99