dbc put

dbc put
	[-after]
	[-before]
	[-current]
	[-partial {doff dlen}]
	data

dbc put
	[-keyfirst]
	[-keylast]
	[-partial {doff dlen}]
	key data  

The dbc put command stores the specified key/data pair into the database. One of the following options must be specified:

If a key is specified, and if the underlying database is a Queue or Recno database, the given key will be interpreted by Tcl as an integer. For all other database types, the key is interpreted by Tcl as a byte array.

If dbc put fails for any reason, the state of the cursor will be unchanged. If dbc put succeeds and an item is inserted into the database, the cursor is always positioned to refer to the newly inserted item.

The dbc put command returns 0 on success, and in the case of error, a Tcl error is thrown.