## Syntax ```mermaid %%{init: { 'theme': 'base', 'flowchart': { 'padding': '7', 'nodeSpacing': '20', 'rankSpacing': '20' }, 'themeVariables': { 'fontSize': '11px', 'fontFamily': 'Arial' } }}%% flowchart LR Start((START)) --> SQLROWCOUNT[SQLROWCOUNT]:::quoted SQLROWCOUNT --> End((END)) ``` ## Purpose The `SQLROWCOUNT` SQL function returns in a PSQL context a long with the number of row influenced by the last SQL statement. In a SQL context `null` is returned. Parameters: - None. ## Examples `SQLROWCOUNT` retrieves the number of rows inserted by the `insert` statement: ```sql begin insert into tab@mssql ( col1 ) select 'x' from range@DataDictionary(5) ; if sqlrowcount = 0 then raise_application_error ( 'code' , 'No rows were loaded.' ); end if; end; ```