If the database already exists, a connection is established and a SQLWarning is issued.
如果该数据库已经存在,就会建立连接并发出SQLWarning。
Before calling the method, you first check that there is at least one SQL warning; if so, you pass the first SQLWarning object to the appropriate method.
在调用这个方法之前,首先要检查是否至少有一个SQL警告;如果有,就将第一个SQLWarning对象传递给适当的方法。
The SQLWarning class inherits from the SQLException class; however, a SQL warning is less severe than an SQL exception, so it's better to handle them separately.
sqlwarning类继承自sqlexception类;但是SQL警告不如SQL异常那么严重,所以更好的方法是分别处理它们。
应用推荐