Skip to content

Commit 8a96ba1

Browse files
foisysandreasprlic
authored andcommitted
/* Loading individual values from objects. */
1 parent 4664d66 commit 8a96ba1

File tree

2 files changed

+6
-4
lines changed

2 files changed

+6
-4
lines changed

_wikis/BioJava:BioJavaXDocs.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2324,15 +2324,15 @@ database. This query retrieves the names of sequences:
23242324

23252325
<java> Query q = session.createQuery("select name from Sequence"); List
23262326
names = q.list(); // list will contain String instances containing the
2327-
names
2327+
names </java>
23282328

23292329
This one returns all the lengths of sequences, which are integers. Note
23302330
the use of sequenceLength, which is the object parameter, and not length
23312331
which is the database table column name:
23322332

2333-
Query q = session.createQuery("select sequenceLength from Sequence");
2334-
List lengths = q.list(); // list will contain Integer instances
2335-
containing the lengths </java>
2333+
<java> Query q = session.createQuery("select sequenceLength from
2334+
Sequence"); List lengths = q.list(); // list will contain Integer
2335+
instances containing the lengths </java>
23362336

23372337
### Deleting objects.
23382338

_wikis/BioJava:BioJavaXDocs.mediawiki

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2231,9 +2231,11 @@ You might not always want to retrieve lists of objects from the database. This q
22312231
<java>
22322232
Query q = session.createQuery("select name from Sequence");
22332233
List names = q.list(); // list will contain String instances containing the names
2234+
</java>
22342235

22352236
This one returns all the lengths of sequences, which are integers. Note the use of sequenceLength, which is the object parameter, and not length which is the database table column name:
22362237

2238+
<java>
22372239
Query q = session.createQuery("select sequenceLength from Sequence");
22382240
List lengths = q.list(); // list will contain Integer instances containing the lengths
22392241
</java>

0 commit comments

Comments
 (0)