pymysql 사용 예제
Photo by Mika Baumeister on Unsplash pymysql을 이용하여 mysql에 데이터를 넣는 코드를 작성했다. 1 2 3 4 5 6 7 8 apt = ‘아크로리버파크’ price = 300000 with connection: with connection.cursor() as cursor: # Create a new record sql = “insert into kb_market_price ( apt_nm, apt_price ) values ( %s, %d )” cursor.execute(sql, (apt, price)) […]