[View]  [Edit]  [Lock]  [References]  [Attachments]  [History]  [Home]  [Changes]  [Search]  [Help] 

test[FMDB] 006 Retrieve some records

| db databasePath rs |
databasePath := 'Sample.sqlite' asLocalPathName.

db := FMDatabase withPath: databasePath.
db open ifTrue: [
	rs := db executeQuery: 'select * from Books where Pages > 200'.
	[rs next ] whileTrue: [
		self print: (' // ', (rs stringForColumn: 'Title')). 
	].
	db close. 
].