# Enterprise Communication Interfacen (ECI)

## ECI supports DataView data type "Blob"

| ECI supports the DataView data type "Blob" which means that e.g. bitmaps can be inserted/read-out via ECI. If you want to read out a bitmap for an item master, enter "T_MASTER_DAT.COL_BLOB" as a return value in the ECI function "eci_rea_ent" . Internally the binary data is changed to strings in the ECI layer. Thus eci_get_par returns the coded binary data. If you want to read out binary data call either eci_get_blb_ptr or eci_get_blb_fil_ptr. It is also possible to specify the blob field (T_MASTER_DAT.COL_BLOB) as a default field when inserting a new item. The default value is then specified with eci_add_blb or eci_add_blb_fil.
| The ECI parameter must be declared with the function eci_cre_par!
| ### Example: Read out a blob: eci_cre_par (&fun_par, 1024); eci_cre_par (&ret_par, 1024); eci_add_par (&fun_par, "EDB-ARTICLE"); eci_end_par (&fun_par); eci_add_par (&fun_par, "EDB-ART-CFR"); eci_end_par (&fun_par); eci_add_par (&fun_par, "off"); eci_end_par (&fun_par); eci_add_par (&fun_par, "form"); eci_end_par (&fun_par); eci_add_par (&fun_par, "bat"); eci_end_par (&fun_par); eci_add_par (&fun_par, "T_MASTER_DAT.PART_ID"); eci_end_par (&fun_par); eci_add_par (&fun_par, "4711"); eci_end_par (&fun_par); eci_add_par (&fun_par, "T_MASTER_DAT.COL_BLOB"); eci_end_par (&fun_par); eci_call (my_header, "eci_rea_ent", &fun_par, &cp_RetCode, &ret_par); if (!strcmp(cp_RetCode, "eci_rea_ent") { eci_set_par(&ret_par, 1); eci_get_blb_ptr(&ret_par, &cp_Blob, %i_BlobSize); } else { /* error */ ... } Insert a blob field: eci_cre_par (&fun_par, 1024); eci_cre_par (&ret_par, 1024); eci_add_par (&fun_par, "EDB-ARTICLE"); eci_end_par (&fun_par); eci_add_par (&fun_par, "EDB-ART-CFR"); eci_end_par (&fun_par); eci_add_par (&fun_par, "form"); eci_end_par (&fun_par); eci_add_par (&fun_par, "bat"); eci_end_par (&fun_par); eci_add_par (&fun_par, ""); eci_end_par (&fun_par); eci_add_par (&fun_par, ""); eci_end_par (&fun_par); eci_add_par (&fun_par, "T_MASTER_DAT.PART_ID"); eci_add_par (&fun_par, "T_MASTER_DAT.COL_BLOB"); eci_end_par (&fun_par); eci_add_par (&fun_par, "4712"); eci_add_blb (&fun_par, cp_Blob, i_BlobSize); eci_end_par (&fun_par); eci_add_par (&fun_par, "T_MASTER_DAT.PART_ID"); eci_end_par (&fun_par); eci_call (my_header, "eci_ins_ent", &fun_par, &cp_RetCode, &ret_par); if (!strcmp(cp_RetCode, "eci_ins_ent") { eci_set_par(&ret_par, 1); eci_get_par(&ret_par, ca_PartId); } else { /* error */ ... }