sqlite

What does COLLATE LOCALIZED ASC stand for?

private Cursor getContacts() { // Run query Uri uri = ContactsContract.Contacts.CONTENT_URI; String[] projection = new String[] { ContactsContract.Contacts._ID, ContactsContract.Contacts.DISPLAY_NAME }; String selection = ContactsContract.Contacts.IN_VISIBLE_GROU...

How to write the query for retrieving id from sqlite database table in iphone apps.

Hi, I am new to using the SQLite database in iphone apps. I have created a database with login table in it and added the database to the project. Login table contains 3 fields "ID", "Username" and "Password" fields. I am entering the username and password in the textfields of the view. Now i am looking of how to retrieve the id from th...

What Operations are not supported in Sqlite Database?

Hello, I have heard that Stored Procedure is not supported in Sqlite DB. is it true ? what are the other operations that are not supported by Sqlite? Which other Db we can use for Iphone? ...

Question about join/update/insert sql query

I am working on making a new sqlite database. Obviously for a number of reasons, structure and organization is important. I have an existing database that is everything that I need, except for one column. So I duplicated the original db, and would like to just swap out that one column with new data from a different column in a different...

AIR application and fast search engine

Hi all, I'm working on a AIR desktop client which will basically be used to search for pictures. For now, the search will only be performed on the picture filename, but I'd like to add a tagging system. I would like the search to be very fast, but I'm not sure SQLite is responsive and fast enought. Do you have any alternatives to sto...

How to get a tables columns arraylist on Android?

I am after a code to get the available column names of a table in Android? I looked around and didn't find anything. ...

Ordering rows depending on user interaction

Suppose I have a table of users. Something like: ID integer, USER text, POSITION integer My db tuples can be: (1, "user1", 1); (2, "user2", 2); (3, "user3", 3); My app lists all users and it has the possibility to reorder it. For example: You can make user3 go before user2. (1, "user1", 1); (2, "user2", 3); (3, "user3", 2); Also...

sqlite: trouble selecting by real values

Hello, I am using an sqlite database to store log data. My table has a lot of 'real' type columns. When I try to execute queries like: SELECT * FROM log WHERE SomeNumber = 61; SELECT * FROM log WHERE SomeNumber='61'; It will return nothing. Queries like: SELECT * FROM log WHERE SomeNumber < 10 SELECT * FROM log WHERE SomeNumber > ...

OperationalError creating an index in sqlite

EDIT: TL;DR version I typed this CREATE INDEX IF NOT EXISTS IDX_FILE_SIZE table_name (file_size); instead of this CREATE INDEX IF NOT EXISTS IDX_FILE_SIZE ON table_name (file_size); Don't do that. ...

SQLiteException Unknown error

Does anyone know what this means? I'm trying to start a transaction in onActivityResult() to insert a row based on the received result. 03-05 15:39:51.937: ERROR/Database(2387): Failure 21 (out of memory) on 0x0 when preparing 'BEGIN EXCLUSIVE;'. 03-05 15:39:51.967: DEBUG/AndroidRuntime(2387): Shutting down VM 03-05 15...

Import/Export CSV from SQLite from C# code

Hi, I am trying to figure out an eazy way to load CSV file into SQLite DB using System.Data.SQLite I saw commandline way to do that i.e .Import mydata.csv mytable But I need to do this via C# code. Any Idea? ...

Incorrect field type mapping SubSonic 2.2, SQLite 3

I have a boolean (BOOL) type field in the SQLite table. In the SubSonic generated DAL it is represented as string (instead of bool). It is weird. How it can be managed? Please, help. ...

How to use my own sqlite database?

I put my database field in "assets" folder. And use the code from this blog to copy the database to "/data/data/my_packname/databases/", (This copy code i run it in the onCreate() method when i run this app) then use select * from ... to get data. But it gives me the exception: no such table. Someone told me that if i am attempting to ...

How to secure passwords in Android Application

Many of my users have requested a password protection for various data elements in my database. Unfortunately, one of my existing features is backing up the database to a public location (SD Card) for data redundancy, so my database isn't secure. So my question is two-fold. How can I encrypt or secure a database on android? How can...

Can't prepare PRAGMA queries on Android

Having this line Cursor c = db.rawQuery("PRAGMA table_info(?)", new String[] {tableName}); and getting this: android.database.sqlite.SQLiteException: near "?": syntax error: , while compiling: PRAGMA table_info(?) Do you know why? ...

SQLite, python, unicode, and non-utf data

I started by trying to store strings in sqlite using python, and got the message: sqlite3.ProgrammingError: You must not use 8-bit bytestrings unless you use a text_factory that can interpret 8-bit bytestrings (like text_factory = str). It is highly recommended that you instead just switch your application to Unicode stri...

sqlite c library on mac os?

Does anyone know what is required to be able to read and write to a sqlite database from a c program on mac os x? I have found the sqlite3 commandline tool on os x, but there doesn't seem to be a sqlite.h file anywhere. It's my understanding that coreData can use the sqlite format, the whole thing is quite confusing. When I have looked f...

Database insert performance.

We are planning to implement a system for logging a high frequency of market ticks into a DB for further analysis. To simply get a little what kind of storage performance we can get on the different DB solutions I created a little application for inserting a basic row of tick information. When running the same code on a couple of differe...

Rails keeps trying to use SQLite , despite that I've configured MySQL for my project.

I setup my rails project "tracks" using: $ rails --database=mysql tracks # OK $ cd tracks $ vim config/database.yml # correct using mysql adapter, added password spec $ rake db:create RAILS_ENV='development' # OK $ rake db:migrate # OK $ ruby script/generate scaffold user name:string password:string email:string url:string # OK $ rake ...

iPhone and SQLite introductory articles or tutorials

What resources are great to provide information on using SQLite for beginner iPhone developers? Where to download the SQLite software for the iPhone? Are there multiple versions, and do they have substantial differences? Where can I find some introductory tutorials? I'm working on an iPhone project where the instructions are to stor...