當前位置: 首頁>>代碼示例>>Python>>正文


Python sqlite3.sqlite_version方法代碼示例

本文整理匯總了Python中sqlite3.sqlite_version方法的典型用法代碼示例。如果您正苦於以下問題:Python sqlite3.sqlite_version方法的具體用法?Python sqlite3.sqlite_version怎麽用?Python sqlite3.sqlite_version使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在sqlite3的用法示例。


在下文中一共展示了sqlite3.sqlite_version方法的12個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Python代碼示例。

示例1: analyze_db

# 需要導入模塊: import sqlite3 [as 別名]
# 或者: from sqlite3 import sqlite_version [as 別名]
def analyze_db():
	conn = sqlite3.connect('WhatsappDB/msgstore.db')	
	cursor = conn.cursor()
	rows=list()

	print 'Module Version ',sqlite3.version
	print 'Library Version ',sqlite3.sqlite_version
	print ""

	for row in cursor.execute('SELECT * FROM messages where edit_version=7 and key_from_me = 1 ORDER BY _id'):
		row_date=str(row[7])
		if len(row_date)>10:
			row_date = row_date[:len(row_date)-3]
		row_date=datetime.datetime.fromtimestamp(int(row_date)).strftime('%Y-%m-%d %H:%M:%S')
		text = "Numero de telefono de whatsapp borrado [>] "+ str(str(row[1]).split("@")[0]) + "\nTimestamp [>] "+row_date
		print text
		rows.append(text)

	cursor.close()
	conn.close()
	return rows 
開發者ID:Quantika14,項目名稱:guasap-whatsapp-foresincs-tool,代碼行數:23,代碼來源:parser_db.py

示例2: check7_sqlite3

# 需要導入模塊: import sqlite3 [as 別名]
# 或者: from sqlite3 import sqlite_version [as 別名]
def check7_sqlite3(self):
        '''sqlite3
        #TODO need to add to required section readme

        https://stackoverflow.com/a/1546162
        '''
        self.append_text("\n")
        # Start check
        #SQLITE_MIN_VERSION = (0, 0, 0)

        try:
            import sqlite3
            # sqlite3.version - pysqlite version
            sqlite3_py_version_str = sqlite3.version
            # sqlite3.sqlite_version - sqlite version
            sqlite3_version_str = sqlite3.sqlite_version
        except ImportError:
            sqlite3_version_str = 'not found'
            sqlite3_py_version_str = 'not found'

        result = ("* SQLite Database library (sqlite3: " +
                  sqlite3_version_str + ") (Python-sqlite3: " +
                  sqlite3_py_version_str + ")")
        # End check
        self.append_text(result) 
開發者ID:gramps-project,項目名稱:addons-source,代碼行數:27,代碼來源:PrerequisitesCheckerGramplet.py

示例3: sys_info

# 需要導入模塊: import sqlite3 [as 別名]
# 或者: from sqlite3 import sqlite_version [as 別名]
def sys_info(cls):
        """Our information for `Coverage.sys_info`.

        Returns a list of (key, value) pairs.

        """
        with SqliteDb(":memory:", debug=NoDebugging()) as db:
            temp_store = [row[0] for row in db.execute("pragma temp_store")]
            compile_options = [row[0] for row in db.execute("pragma compile_options")]

        return [
            ('sqlite3_version', sqlite3.version),
            ('sqlite3_sqlite_version', sqlite3.sqlite_version),
            ('sqlite3_temp_store', temp_store),
            ('sqlite3_compile_options', compile_options),
        ] 
開發者ID:nedbat,項目名稱:coveragepy,代碼行數:18,代碼來源:sqldata.py

示例4: about

# 需要導入模塊: import sqlite3 [as 別名]
# 或者: from sqlite3 import sqlite_version [as 別名]
def about(self):
        try:
            import pulp
        except ImportError:
            pulp_version = "(missing!)"
        else:
            pulp_version = pulp.VERSION
        try:
            import sqlite3
        except ImportError:
            sqlite_version = "(missing!)"
        else:
            sqlite_version = sqlite3.sqlite_version
        
        QMessageBox.information(None, "About", """
            <h1>{}</h1>
            <h3>Version {}</h3>

            <p>&copy; 2014-2016 Oleh Prypin &lt;<a href="mailto:blaxpirit@gmail.com">blaxpirit@gmail.com</a>&gt;<br/>
            &copy; 2014 Stefan Walzer &lt;<a href="mailto:sekti@gmx.net">sekti@gmx.net</a>&gt;</p>

            <p>License: <a href="http://www.gnu.org/licenses/gpl.txt">GNU General Public License Version 3</a></p>

            Using:
            <ul>
            <li>Python {}
            <li>Qt {}
            <li>{} {}
            <li>PuLP {}
            <li>SQLite {}
            </ul>
        """.format(
            self.title, __version__,
            sys.version.split(' ', 1)[0],
            qt.version_str,
            qt.module, qt.module_version_str,
            pulp_version,
            sqlite_version,
        )) 
開發者ID:oprypin,項目名稱:sixcells,代碼行數:41,代碼來源:common.py

示例5: appDBDebugInfo

# 需要導入模塊: import sqlite3 [as 別名]
# 或者: from sqlite3 import sqlite_version [as 別名]
def appDBDebugInfo(self):
        logger.debug("Sqlite database adapter version: %s" % sqlite3.sqlite_version) 
開發者ID:mbevilacqua,項目名稱:appcompatprocessor,代碼行數:4,代碼來源:appDB.py

示例6: get_summary

# 需要導入模塊: import sqlite3 [as 別名]
# 或者: from sqlite3 import sqlite_version [as 別名]
def get_summary(cls):
        """
        Return a dictionary of information about this database backend.
        """
        summary = {
            "DB-API version": "2.0",
            "Database SQL type": cls.__name__,
            "Database SQL module": "sqlite3",
            "Database SQL Python module version": sqlite3.version,
            "Database SQL module version": sqlite3.sqlite_version,
            "Database SQL module location": sqlite3.__file__,
        }
        return summary 
開發者ID:GenealogyCollective,項目名稱:gprime,代碼行數:15,代碼來源:sqlite.py

示例7: connect_db

# 需要導入模塊: import sqlite3 [as 別名]
# 或者: from sqlite3 import sqlite_version [as 別名]
def connect_db(self):
        """Connect to the database

        Simply connect to the database at location <path>
        """
        try:
            logger.debug("connect db: %s", self.db)
            self.con_db = sqlite3.connect(self.db)
            self.cursor = self.con_db.cursor()
            logger.debug(sqlite3.sqlite_version)
        except Exception as e:  # pylint: disable=broad-except
            logger.debug(e) 
開發者ID:greenbone,項目名稱:gvm-tools,代碼行數:14,代碼來源:check-gmp.gmp.py

示例8: load_tests

# 需要導入模塊: import sqlite3 [as 別名]
# 或者: from sqlite3 import sqlite_version [as 別名]
def load_tests(*args):
    if test.support.verbose:
        print("test_sqlite: testing with version",
              "{!r}, sqlite_version {!r}".format(sqlite3.version,
                                                 sqlite3.sqlite_version))
    return unittest.TestSuite([dbapi.suite(), types.suite(),
                               userfunctions.suite(),
                               factory.suite(), transactions.suite(),
                               hooks.suite(), regression.suite(),
                               dump.suite()]) 
開發者ID:Microvellum,項目名稱:Fluid-Designer,代碼行數:12,代碼來源:test_sqlite.py

示例9: preloop

# 需要導入模塊: import sqlite3 [as 別名]
# 或者: from sqlite3 import sqlite_version [as 別名]
def preloop(self):
        print('sqlite3 version %s' % sqlite3.sqlite_version)
        print('.(dot) is used for all none sql commands.')
        print('Use .help for non sqlite command list')
        print('All sql commands must end with ;')
        if self.database == ':memory:':
            print('Using database :memory:\nuse .open ?file? to open a database')
        else:
            print('Using databasse: %s' % self.database) 
開發者ID:ywangd,項目名稱:stash,代碼行數:11,代碼來源:sqlite.py

示例10: check_runtime_requirements

# 需要導入模塊: import sqlite3 [as 別名]
# 或者: from sqlite3 import sqlite_version [as 別名]
def check_runtime_requirements():
    if sqlite3.sqlite_version_info < (3, 9, 0):
        raise RuntimeError("Need sqlite version >= 3.9.0, you have: %r" % (sqlite3.sqlite_version,)) 
開發者ID:rianhunter,項目名稱:dbxfs,代碼行數:5,代碼來源:cachingfs.py

示例11: _xray_traced_connect

# 需要導入模塊: import sqlite3 [as 別名]
# 或者: from sqlite3 import sqlite_version [as 別名]
def _xray_traced_connect(wrapped, instance, args, kwargs):

    conn = wrapped(*args, **kwargs)

    meta = {}
    meta['name'] = args[0]
    meta['database_version'] = sqlite3.sqlite_version

    traced_conn = XRayTracedSQLite(conn, meta)

    return traced_conn 
開發者ID:aws,項目名稱:aws-xray-sdk-python,代碼行數:13,代碼來源:patch.py

示例12: load_tests

# 需要導入模塊: import sqlite3 [as 別名]
# 或者: from sqlite3 import sqlite_version [as 別名]
def load_tests(*args):
    if test.support.verbose:
        print("test_sqlite: testing with version",
              "{!r}, sqlite_version {!r}".format(sqlite3.version,
                                                 sqlite3.sqlite_version))
    return unittest.TestSuite([dbapi.suite(), types.suite(),
                               userfunctions.suite(),
                               factory.suite(), transactions.suite(),
                               hooks.suite(), regression.suite(),
                               dump.suite(),
                               backup.suite()]) 
開發者ID:bkerler,項目名稱:android_universal,代碼行數:13,代碼來源:test_sqlite.py


注:本文中的sqlite3.sqlite_version方法示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。