Prexx
Prexx

Reputation: 2979

combine columns of SQLite3 SELECT-statement

i need something like

SELECT (Name & ', ' & Firstname) AS Test FROM Person;

which returns something like

Simpson, Homer
Simpson, Bart
...

in the column 'Test'.

Is it possible to create such a statement in SQLite3 (for android developing).

Thanks.

Upvotes: 0

Views: 232

Answers (1)

Vincent Mimoun-Prat
Vincent Mimoun-Prat

Reputation: 28541

Use the || operator:

SELECT (Name || ', ' || Firstname) AS Test FROM Person;

Upvotes: 2

Related Questions