This looks like correct syntax to me as of Stata 10.1 -- and indeed all
previous versions of -tostring- that I can recall.
A different issue is that -tostring- with dates and without options is
unlikely to do what you want. You say nothing about what you want, but I
doubt it is what -tostring- does to dates by default.
For example, if your variable contains today's date as a value then the
string equivalent is "17845".
Nick
[email protected]
Fabian Brenner
tostring date, generate(date_as_string)
leads to:
option generate() not allowed
r(198);
what is wrong?
*
* For searches and help try:
* http://www.stata.com/help.cgi?search
* http://www.stata.com/support/statalist/faq
* http://www.ats.ucla.edu/stat/stata/