user3781353
user3781353

Reputation: 41

42601:Token * was not valid DB2 for IBM i (AS400)

I would like to insert in a DB2 AS 400 database. I would like to insert a string that includes an asterisk. I receive the error

42601:Token * was not valid (list of valid tokens) SQL code 104

Searching in the Internet generally, and stackoverflow specifically has not revealed relevant information.

Upvotes: 0

Views: 1586

Answers (1)

Mureinik
Mureinik

Reputation: 310983

String literals in SQL are denoted by single quotes ('). It seems your statement had omitted them, and hence the error. Applying them to your value should do the trick:

INSERT INTO tableName (columnName) VALUES ('*text') 

Upvotes: 3

Related Questions