bayonet icon indicating copy to clipboard operation
bayonet copied to clipboard

数据库连接字符问题

Open ximiluliyi opened this issue 5 years ago • 1 comments

师傅, 请问下关于数据库连接字符: SQLALCHEMY_DATABASE_URI = 'postgresql://postgres:qazxsw@[email protected]/bayonet' 其中postgresql postgres qazxsw@123 bayonet这几个参数各自代表什么? 新手查了半天资料无获,谢谢~

ximiluliyi avatar Mar 16 '20 02:03 ximiluliyi

师傅, 请问下关于数据库连接字符: SQLALCHEMY_DATABASE_URI = 'postgresql://postgres:qazxsw@[email protected]/bayonet' 其中postgresql postgres qazxsw@123 bayonet这几个参数各自代表什么? 新手查了半天资料无获,谢谢~

postgresql://postgres:qazxsw@[email protected]/bayonet

  • postgres:qazxsw@123 数据库用户名和密码
  • 127.0.0.1 数据库连接地址
  • bayonet 数据库名

格式:dialect+driver://username:password@host:port/database

多种数据库连接形式:

Postgres: postgresql://scott:tiger@localhost/mydatabase

MySQL: mysql://scott:tiger@localhost/mydatabase

Oracle: oracle://scott:[email protected]:1521/sidname

CTF-MissFeng avatar Mar 16 '20 02:03 CTF-MissFeng