why does variable instantation contain syntax error?
Question:
I’m learning python. It gives syntax error in this script. I’m unable to figure out.
conn = psycopg2.connect(
host = str(Ip)
user = "test"
password="test1234")
the error:
user^= "test"
^
SyntaxError: invalid syntax
There is something wrong with the user variable instantiation according to the compiler.. I have no knowledge of how to solve this..
Answers:
I think the =^ operator doesn’t exist, the code lacks indentation and commas between arguments you pass inside connect() call
I’m learning python. It gives syntax error in this script. I’m unable to figure out.
conn = psycopg2.connect(
host = str(Ip)
user = "test"
password="test1234")
the error:
user^= "test"
^
SyntaxError: invalid syntax
There is something wrong with the user variable instantiation according to the compiler.. I have no knowledge of how to solve this..
I think the =^ operator doesn’t exist, the code lacks indentation and commas between arguments you pass inside connect() call