I have a large dataset where I need my industry code to be 5 digits. However, I know that some are 4 digits and so I would like to insert a 0 infront of the value such that it would appear like this: 01234, instead of 1234 (as it is now). Below I show data that I have, and then how I wish the outcome to look like.
What I have:
companyID year industry_code
1 2008 12345
1 2009 12345
1 2010 12345
2 2015 1234
2 2016 1234
3 2000 5678
3 2001 5678
3 2002 5678
3 2003 5678
I do not know which ones are 4 digits I just know that they exist.
Needed outcome:
companyID year industry_code
1 2008 12345
1 2009 12345
1 2010 12345
2 2015 01234
2 2016 01234
3 2000 05678
3 2001 05678
3 2002 05678
3 2003 05678
thank you in advance, super appreciative of your help!!