I tried to convert my key variable "name" from strL to str# to merge two datasets.
However, the error code r(109) continues to occur.
I've tried the following:
. describe name
storage display value
variable name type format label variable label
--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
name strL %-20s Name of owning party <party-name>
. gen len=length(name)
. summ len
Variable | Obs Mean Std. Dev. Min Max
-------------+---------------------------------------------------------
len | 21,022,429 22.72522 9.84456 1 818
. recast str818 name, force
name: str818 invalid
r(109);
Also, I tried to compress command then I obtained
. compress name
(0 bytes saved)
Does anyone have an idea to solve this problem?
Thanks in advance
Related Posts with convert strL to str#
Replace values from bottom to topDear Statalists, I have a dataset in the following shape for several counties and years: County Ye…
Merge m:1 using participant ID in matched case-control data - error messagesHi, I have a matched case control dataset with 3 controls to every case. I have data that I want to…
Stata16 MG, PMG estimationsPlease, any help for Stata16 commands for MG, PMG estimations? Thank you …
Stata dates - combining data from two variables to create a Stata date variableHi All I have a variable date2 which holds information on month and year of medical examination: t…
Help in 'moving common' commandI have an unbalanced panel, say firms over years, each firm has a variable of interest. I would like…
Subscribe to:
Post Comments (Atom)
0 Response to convert strL to str#
Post a Comment