Ò׽ؽØͼÈí¼þ¡¢µ¥Îļþ¡¢Ãâ°²×°¡¢´¿ÂÌÉ«¡¢½ö160KB

Sqlite DBʹÓÃÀý×Ó

Ç°Ò»Õó×Ö×öÏîÄ¿(ǶÈëʽlinux)£¬ÓÉÓÚÒª±£´æ´óÁ¿µÄÊý¾Ý£¬¶øÇÒ×Ҫ±£´æ30ÌìµÄʱ¼ä¡£±¾À´´òËã±£´æµ½ÎļþÖУ¬Ã¿´ÎÆô¶¯Ó¦ÓóÌÐòµÄʱºòÖØнâÎöÒ»±é£¬¿ÉÊǵ±Êý¾ÝÁ¿ºÜ´óµÄʱºò£¬¾Í³öÏÖЧÂʵÄÎÊÌâÁË¡£ËùÒÔ×îºó»¹ÊÇ·ÅÆúÁËʹÓÃÎļþµÄ´òË㣬¾ö¶¨Ê¹ÓÃÊý¾Ý¿â´æÈ¡Êý¾Ý¡£
linuxϵÄÊý¾Ý¿âÒ²ºÜ¶à£¬ÓпªÔ´µÄ£¬Ò²ÓÐÊշѵġ£¶ÔÓÚÎÒÃÇÀ´Ëµ£¬¿Ï¶¨ÒªÊ¹ÓÿªÔ´µÄÊý¾Ý¿â¡£ÒÔÇ°ÓùýBerkely DB£¬µ«ÊÇÐèÒªlicience¡£ËùÒÔ½áºÏЧÂÊÐÔÄÜÒÔ¼°´óСÏÞÖÆ£¬×îÖÕÑ¡¶¨ÁËSqlite DB¡£ÎÒÃǶÔËüµÄÆÀ¼ÛÊÇ“sqliteÊÇÒ»¸öÓÅÐãµÄÍêÈ«freeµÄ¿ªÔ´Êý¾ÝÏîÄ¿”¡£
ÏÂÃæÊÇÒ»¸ö¼òµ¥µÄʹÓÃʵÀý£º
int main( int argc, char **argv )
{
        sqlite3 *db;
        sqlite3_stmt * stmt;
        const char *zTail;
        //´ò¿ªÊý¾Ý¿â
        int r = sqlite3_open("mysqlite.db",&db)
        if(r){
                printf("%s",sqlite3_errmsg(db));
        }
        //´´½¨Table
        sqlite3_prepare(db,
                "CREATE TABLE players ( ID INTEGER PRIMARY KEY, name TEXT, age INTERER );",
                -1,&stmt,&zTail);
        sqlite3_step(stmt);
        sqlite3_finalize(stmt);
        //²åÈëÊý¾Ý
        sqlite3_prepare(db,
                "INSERT INTO players (name,num) VALUES(?,?);",
             &nbs


Ïà¹ØÎĵµ£º

sqlite½â¾öÖÐÎÄ·¾¶ÎÊÌâ


// sqlite½â¾öÖÐÎÄ·¾¶ÎÊÌâ,ÒÔÇ°Ñо¿sqliteʱºòÓöµ½µÄÖÐÎÄ·¾¶ÎÊÌâµÄ½â¾ö·½·¨
// AnsiString cbÖеÄ×Ö·û´®Àà,ÆäËü±àÒëÆ÷ÓÃstd::stringÌæ»»¼´¿É.
// MultiByteToWideCharÊÇwindows api
AnsiString fileName;   
int strSize = fileName.Length();
char *ansi = new char[strSize+1];
wchar_t *unico ......

ÈçºÎ¸ßЧʹÓÃSQLite .net (C#)

 SQLite ×÷Ϊһ¸öÇáÁ¿¼¶Ç¶ÈëʽÊý¾Ý¿â£¬»¹ÊǷdz£ºÃÓõġ£ÓêºÛ¼«Á¦ÍƼö~~~~~~ 
½ñÌìÓиöÅóÓѲâÊÔ SQLite£¬È»ºóµÃ³öµÄ½áÂÛÊÇ£ºSQLite ЧÂÊÌ«µÍ£¬ÅúÁ¿²åÈë1000Ìõ¼Ç¼£¬¾ÓÈ»ºÄʱ 2 ·ÖÖÓ£¡
ÏÂÃæÊÇËû·¢¸øÎҵIJâÊÔ´úÂë¡£ÎÒÔÎ~~~~~~ 
using System.Data;
using System.Data.Common;
using System.Data.SQLite; ......

Python sqlite3ºÍµ¥Ôª²âÊÔ

 
import os
import unittest # °üº¬µ¥Ôª²âÊÔÄ£¿é
import sqlite3 as sqlite # °üº¬sqlite3Ä£¿é
def get_db_path():
return "sqlite_testdb"
class TransactionTests(unittest.TestCase): # µ¥Ôª²âÊÔµÚÒ»²½:¡¡ÓÉTestCaseÅÉÉúÀà
def setUp(self): # µ¥Ôª²âÊÔ»·¾³ÅäÖÃ
......

SQLiteÖеÄÈ«ÎÄËÑË÷

    °ÝGoogleµÄScott Hessͬ־Ëù´Í£¬SQLiteÒ²ÍƳöÁËÈ«ÎÄËÑË÷¹¦ÄÜ¡£
    SQLiteͨ¹ý½¨Á¢Ò»¸öÐéÄâ±í£¬½«ÊäÈëµÄÎÄ×Ö¸ù¾Ý¿Õ¸ñ¡¢±êµã·ûºÏµÈ¹æÔò½øÐзִʣ¬×éÖ¯³ÉÒ»¿ÃBÊ÷£¬ÒÔ´ËÀ´Ìá¸ßËÑË÷Ëٶȡ£
    ÈçºÎʹÓÃÕâÒ»¹¦ÄÜ£¬ÐÔÄÜÉÏÈçºÎ£¬´ó¼Ò¸÷×ÔÑо¿È¥°É¡£
    ÔÚÕâÀ ......

Qt£ºSQLite 3ÈëÃŽ̳Ì


OS X×Ô´Ó10.4ºó°ÑSQLiteÕâÌ×Ï൱³öÃûµÄÊý¾Ý¿âÈí¼þ£¬·Å½øÁË×÷ҵϵͳ¹¤¾ß¼¯Àï¡£OS X°ü×°µÄÊǵÚÈý°æµÄSQLite£¬ÓÖ³ÆSQLite3¡£ÕâÌ×Èí¼þÓм¸¸öÌØÉ«£º
Èí¼þÊôÓÚ¹«¹²²Æ£¨public domain£©£¬SQLite¿É˵ÊÇijÖÖ¡¸ÃÀµÂÈí¼þ¡¹£¨virtueware£©£¬×÷Õß±¾ÈË·ÅÆú×Å×÷Ȩ£¬¶ø¸øʹÓÃSQLiteµÄÈËÒÔϵġ¸×£¸£¡¹£¨blessing£©£º
May you do good an ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØͼ | ¸ÓICP±¸09004571ºÅ