Hello. I am having a few issues and was looking for a bit of help. I am currently working on the Mario database using PostgreSQL.
The first problem is when inputting values into the table I think I cause this problem by leaving out one of the parentheses out. The prompt will change from => to (> beside the database I am currently working in. I looked at some documentation and from what I can tell is that I am breaking up the code by doing that? I thought the semicolon would have ended the code though so I was refreshing the page to fix it which leads me to the next problem.
Yeah they are. The directions for this task was to add two more rows with one command and I didn’t close out the first set of parentheses. I am not sure though why at end of this line of code when there was a semicolon would it want to continue this line of code after I press enter instead if giving a error message. I am assuming that is why the prompt change from => to (> to spread the code across several lines. This picture will also help show why I came to this conclusion but I am unsure if it is the right conclusion. I wasn’t able to do much after I believe. I was able to run \d to display the tables. Also in the picture above you can see the command for SELECT being run but nothing happen. I am just not sure what is happening to be honest.
Me neither. Your question is vague. But a semicolon ; fires the query. To select and insert in the same query, you must have some sort of CTE (WITH clause etc).
To insert several records in ONE query, you can just add the data separated with comma (,) and a semicolon (;) at the end. You do not have to specify the columns if the data is exact same order as the columns.
INSERT INTO tsk VALUES
The psql shell allows you to put a command on multiple lines since some queries can be quite long. So if you press enter using a command that is incomplete, it will allow you to just continue the command. The (> prompt means that a parenthesis is missing. You should be able to finish the command by entering ); in the prompt (the closing parenthesis and semi-colon to finish the command). I’ve also seen '>. That one would be missing a single quote - so '; would finish the command.
I have not seen the coderoad: start not found error before. You could try just hitting okay, and then attempt to start it back up. There’s a gif on how to start it manually in the link @ilenia shared. If that doesn’t work, you could try another page refresh and see if it happens again. Let us know if either of these work.