Skip to content

Commit 7cfcab2

Browse files
committed
Prefer vanilla indexeddb over the webkit flavor and other Safari-related tweaks.
1 parent 00745f5 commit 7cfcab2

File tree

1 file changed

+13
-3
lines changed

1 file changed

+13
-3
lines changed

README.md

Lines changed: 13 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
# jSQL
2-
v1.1
2+
v1.3
33

44
Too often web applications rely on server side databases to store state information, causing unnecessary strain on the server and longer load time for the end user. jSQL aims to solve the quandary of the stateless web by using various APIs to store serialized data structures on the user's hard drive.
55

@@ -20,7 +20,11 @@ jSQL is written with flexibility, ease of use, and efficiency in mind. It suppor
2020
jSQL is implemented in a single JavaScript file. Save the [`jSQL.js`](https://github.com/Pamblam/jSQL/blob/master/jSQL.js) file (or if for performance junkies, the minified [`jSQL.min.js`](https://github.com/Pamblam/jSQL/blob/master/jSQL.min.js) file) to your project folder and include it.
2121

2222
<script src='jSQL.js'></script>
23-
23+
24+
25+
26+
#### Create a table
27+
2428
When the database has loaded into memory, you'll want to make sure you have a table to work with. Any database operations that are to be made immediately when the app loads should be called from within the [`jSQL.load()`](https://github.com/Pamblam/jSQL/wiki/Persistence-Management#jsqlloadonloadcallback) callback.
2529

2630
jSQL.load(function(){
@@ -30,6 +34,10 @@ When the database has loaded into memory, you'll want to make sure you have a ta
3034
// jSQL.createTable({users: {name: {type:varchar, args: 25}, age: {type: int}}}).ifNotExists().execute();
3135
});
3236

37+
38+
39+
#### Insert into table
40+
3341
At some point, you might want to put some data in that table.
3442

3543
jSQL.query("insert into users ('bob', 34)").execute();
@@ -46,6 +54,8 @@ You can use prepared statements in low level syntax too:
4654

4755
jSQL.insertInto('users').values({name:'?', age:'?'}).execute(['bob',34]);
4856

57+
#### Select from table
58+
4959
Once you've got the data in there, you're probably going to want to get it back out.
5060

5161
var users = jSQL.query("select * from users where name like '%ob'").execute().fetchAll("ASSOC");
@@ -56,7 +66,7 @@ The low level select sytax is easy too:
5666

5767
When you've made changes or additions to the database, call [`jSQL.persist()`](https://github.com/Pamblam/jSQL/wiki/Persistence-Management#jsqlpersist) to commit your changes.
5868

59-
For more information and to read about other query types, see the [jSQL Documentation](https://github.com/Pamblam/jSQL/wiki#jsql-docs).
69+
For more information and to read about other update, delete and other operations, see the [jSQL Wiki](https://github.com/Pamblam/jSQL/wiki#jsql-docs).
6070

6171
<hr>
6272

0 commit comments

Comments
 (0)