Announcement

Collapse
No announcement yet.
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • Arising the error r(608)

    Dear STATA list members,

    While in the process of executing 1000s of lines of commands at one go, an error is appearing. It says the file XXX.dta is read only; cannnot be modified or erased. Please see below:
    Click image for larger version

Name:	Screenshot (42).png
Views:	1
Size:	14.8 KB
ID:	1750890


    To avoid this error, the memory size had been increased already by calling the following command before execute the 1000s of lines of commands.

    ["set max_memory 32g, permanently"]

    But still the problem persists. Any kind help would be highly appreciated.



  • #2
    Getting an error message from the -save- command saying that the file cannot be modified or erased doesn't, to me, suggest that the solution would be to increase memory. The possibilities I would consider first are:
    1. The file really is read-only. Go to your operating system and check its attributes.
    2. The directory in which the file is located, or some directory on the path leading to it, is read-only. Check those attributes as well.
    3. The file you are thinking of is OK, as its directory, but the current working directory is a different directory and is read-only. Run -pwd- to see what the current working directory is. If it's not the one where your file should be, change it using the -cd- command.
    As an aside, having, I think, nothing at all to do with the question are raising, I notice you are using -merge m:m-. -merge m:m- is always wrong. It should never be used. (Read the PDF documentation for -merge-: it even says this there.) It produces data salad. So it is just as well that Stata is unable to save the erroneous file you have created. You should be using merge 1:1, 1:m, or m:1, or -joinby- to combine these files. If none of those work, then it means that either your data are wrong, or are unsuitable for combination, or you don't understand the relationships between the data sets.

    Comment


    • #3
      Dear Clyde, your suggestions induced to improve my technical skills. Also, the suggestion for merge clears my longtime doubt. It is greatful, Thank you so much.

      Comment

      Working...
      X