易截截图软件、单文件、免安装、纯绿色、仅160KB

AutoIt3开发的操作SQlite数据库的源码

AutoIt3开发的操作SQlite数据库的源码下载
部分源码
_SQLite_Startup () ;加载 SQLite.dll
If Not FileExists($SQLite_Data_Path) Then
    SQLCreate()
EndIf
$GUI_Form = GUICreate($Title, 300, 435, -1, -1)
GUISetBkColor(0xECE9D8)  ; will change background color
$GUI_ListBox = GUICtrlCreateListView("", 2, 2, 296, 309, 0x0010)
_GUICtrlListView_AddColumn($GUI_ListBox, "编号", 100, 0)
_GUICtrlListView_AddColumn($GUI_ListBox, "姓名", 80, 1)
_GUICtrlListView_AddColumn($GUI_ListBox, "年龄", 80, 1)
GUICtrlCreateLabel("编号         姓名         年龄", 34, 325, 240, 15)
$GUI_Input1 = GUICtrlCreateInput("", 10, 341, 73, 20)
$GUI_Input2 = GUICtrlCreateInput("", 88, 341, 73, 20)
$GUI_Input3 = GUICtrlCreateInput("", 166, 341, 73, 20)
$GUI_Input4 = GUICtrlCreateInput("", 88, 366, 73, 20)
$GUI_Input5 = GUICtrlCreateInput("", 88, 391, 73, 20)
$GUI_Button1 = GUICtrlCreateButton("读取", 246, 315, 48, 22, 0)
$GUI_Button2 = GUICtrlCreateButton("写入", 246, 340, 48, 22, 0)
$GUI_Button3 = GUICtrlCreateButton("查找", 246, 365, 48, 22, 0)
$GUI_Button4 = GUICtrlCreateButton("删除", 246, 390, 48, 22, 0)
GUICtrlCreateGroup("", 2, 307, 296, 107)
完整源码下载


相关文档:

SQLITE SQL语句的注意


1 TOP
这是一个大家经常问到的问题,例如在SQLSERVER中可以使用如下语句来取得记录集中的前十条记录:
SELECT TOP 10 * from [index] ORDER BY indexid DESC;
但是这条SQL语句在SQLite中是无法执行的,应该改为:
SELECT * from [index] ORDER BY indexid DESC limit 0,10;
其中limit 0,10表示从第0条记录开始,往后 ......

SQLite Database判断是否存在、新建、删除.....

 Android SQLite Database本打算封装SQLite的,但是,发现实际上Android已经封装了一层,尤其是数据的增、删、查、改上,更是如此,所以,我后来只封装了一个连接层,负责打开、建立数据库,并返回一个SQLite的实例用来完成增、删、插、改等操作。
//----------- DBHelper -------------
package utility.db;
import ja ......

SQLite与C结合

SQLite官方网站例子:
#include <stdio.h>
#include <sqlite3.h>
static int callback(void *NotUsed, int argc, char **argv, char **azColName){
int i;
for(i=0; i<argc; i++){
printf("%s = %s\n", azColName[i], argv[i] ? argv[i] : "NULL");
}
printf("\n");
return 0;
}
i ......

SQLite数据库的增删改查代码

//搜集整理了一下网上的代码.找了半天居然找不到一条插入语句.好郁闷的
//感觉速度还可以.小文件.很多小应用程序在用这个数据库
//SQLite使用办法.直接COPYDLL文件System.Data.SQLite.DLL到应用程序DEBUG目录下。 然后在项目中添加引用,找到这个文件即可
//添加引用
using System;
using System.Collections.Generic; ......
© 2009 ej38.com All Rights Reserved. 关于E健网联系我们 | 站点地图 | 赣ICP备09004571号