I have a question regarding the renaming of the table using the dbmaint.q function… I believe my error is about the database directory, but I cannot figure it out (screenshot attached - the \cd command may not play any role, as I am already in the \pwd directory, but I am not sure). Moreover, the \ls command does not work - should I add the “system” instruction line? I tried the tutorials as well but did not really understand how to access the \pwd, \ls, \cd instructions.
I would recommend running your code in the scratchpad. This will allow you to run each command line by line, instead of in the markdown file where everything in the code block will run.
You run system commands using (System commands in q) or you can use the “system” operator (system keyword) whichever you are more comfortable using.
I can’t see an error in your screenshot, you’ll need to screenshot the output console for me to see what is happening, however you are correct that you don’t need the \cd command as you should already be in the correct directory after loading the f1 database.
For your renamecol function, take another look at the first argument, and double check the syntax you are using - to make sure your directory is correct you could input the whole directory in full, or assign it to a variable that can be reused.
Thank you for your suggestion! I tried using the system ls command to check my directories in the pwd. However, when I run the renamecol command, I only get the red error at the bottom of the screenshot. This happens for both of the commands renamecol.