Page 19 - project IP DEEPAK Full for youtub
P. 19
mycursor.execute('insert into custdet
values("{n}",{f},{op},{m},"{a}")'.format(n=name,f=fid,op=orp,m=mno,
a=add))
mydb.commit()
print('======================')
if c==3:
cn=input('Enter customer name:')
print('======================')
q1=('select * from custdet where
customer_name="{}"'.format(cn))
mycursor.execute(q1)
data=mycursor.fetchone()
print(pd.DataFrame(data, index=['Name','f_id','Ord
price','mobile no','address'], columns=['info']))
print('======================')
if c==4:
cn=input('Enter customer name:')
print('======================')
q1=('select order_price from custdet where
customer_name="{}"'.format(cn))
mycursor.execute(q1)
data=mycursor.fetchone()
print(pd.DataFrame(data, index=['Rs'], columns=["Order
price is"]))