Question: I can't insert a value using this code:

```
 insert into t_category_values (CategoryCode,
 CategoryValueCode, CategoryValue) values(2, 1, 1);

```

error msg

```
no primary key

```

Answer: 
Try this (**edited** because you use Sybase SQL Anywhere):

```
INSERT INTO dba.t_category_values
(CategoryCode, CategoryValueCode, CategoryValue)
VALUES(1, 1, 'aaa');

```

**EDITED:**  

from [Sybase web page](http://manuals.sybase.com/onlinebooks/group-pbarc/conn5/sqlug/@Generic__BookTextView/4620;pt=1435/%2a):
Adding rows to a table

Suppose that a new eastern sales department is created, with the same manager as the current Sales department. You can add this information to the database using the following INSERT statement:

```
 INSERT
 INTO department ( dept_id, dept_name, dept_head_id )
 VALUES ( 220, 'Eastern Sales', 902 )

```

If you make a mistake and forget to specify one of the columns, SQL Anywhere reports an error.

The NULL value is a special value used to indicate that something is either not known or not applicable. Some columns are allowed to contain the NULL value, and others are not.
Insert query eg:-

```
Insert into `tableName`(field1, field2, field3) values ('value1', 'value2', 'value3');

```