user_id=`mysql -N$mysqld${DBNAME2}-e"select id from ${TABLENAME4} where phone_no=${phone_no}"`
protocol_number=`mysql -N$mysqld${DBNAME1}-e"select ssq_contract_no from ${TABLENAME5} where loan_application_history_id=${loan_application_history_id}"`
echo$protocol_number
con3="INSERT INTO gyxd.loan_application_manifest_history(loan_id,loan_user_id,channel_id,credit_assignment,bank_card_id,loan_progress,reported_progress,amount,term, purpose,protocol_number,service_fee_per_term,total_repayment_amount,monthly_repayment,annual_interest_rate,principal_and_interest_per_term,total_principal_and_interest,loan_received_at,loan_paid_at,transaction_status,remark,payment_notification_url,created_at,updated_at,notify_at,sign_status,loan_status,recall_status, repay_status,debt_status,distribute_fund_id,credit_assigned_at)