conn = psycopg2.connect(host='localhost',
                        user='franta',
                        password='tojetajny',
                        database='lididb')
with conn, conn.cursor() as curs:
    curs.execute("INSERT INTO zamestnani (nazev) VALUES ('blabla');")
    curs.execute("INSERT INTO konicek (nazev) VALUES ('horolezeni');")
