:orphan:
# PetscHMapIVAddValue
Add value to the value of a given key if the key exists, otherwise, insert a new (key,value) entry in the hash table 
## Synopsis
```
#include <petsc/private/hashmapiv.h>
PetscErrorCode PetscHMapIVAddValue(PetscHMapT ht,PetscInt key,PetscScalar val)
```

## Input Parameters

- ***ht  -*** The hash table
- ***key -*** The key
- ***val -*** The value





## See Also
 `PetscHMapIVGet()`, `PetscHMapIVIterSet()`, `PetscHMapIVSet()`

## Level
developer

## Location
<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/include/petsc/private/hashmapiv.h.html#PetscHMapIVAddValue">include/petsc/private/hashmapiv.h</A>


---
[Edit on GitLab](https://gitlab.com/petsc/petsc/-/edit/release/include/petsc/private/hashmapiv.h)


[Index of all Sys routines](index.md)  
[Table of Contents for all manual pages](/manualpages/index.md)  
[Index of all manual pages](/manualpages/singleindex.md)  
