Return a value if no rows are found SQL

SQL

What actually happens when you run a SQL query that doesn’t return any rows? For example, think of a WHERE clause with the condition 1=2, which can never be fulfilled and therefore rows can never be returned. First, let’s look at a few examples that should show you what you can expect as a return … Read more

SQL Default Value if no row is returned

SQL

Sometimes default values are necassary. Normally you can use NVL or NVL2 when you get NULL values as return value. But it is also possible, that no row is returned. In this case, NVL or NVL2 is not working, cause you get no value back – not even NULL. Therefore, there are some options – … Read more

Commit and Rollback SQL Developer

Commit Rollback SQLDEV

The SQL Developer sets implicit automatic COMMITs. This COMMIT is subconsciously and automatically canceled in the following situations. (1) SQL Developer quits normally, with no COMMIT or ROLLBACK statement. In this case, a COMMIT is sent before the program is terminated. However, this does not happen in the event of a system failure of the … Read more