> For the complete documentation index, see [llms.txt](https://help.besmart.software/erpc/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://help.besmart.software/erpc/data-interface-reference-manual/importing-data-into-a-vault/writing-data-into-data-interface/using-sql-stored-procedure/example-1-insert-single-ecentity-record.md).

# Example #1 – insert single EcENTITY record

used to transfer data of a created or updated purchased item from ERP to Vault

```sql
DECLARE @EntName nvarchar(100), @EntId bigint;
SET @EntName = 'PurchItem 987';
EXEC @EntId = EcWriteEntity @EntName
UPDATE EcENTITY SET category = 'Purchased', txt00 = 'BOLT M10 x 25mm, GOLD-COATED', comm_status = 0 WHERE id = @EntId;
SELECT @EntId;
```
