Oracle 23ai: Table Value Constructors

Oracle Database 23ai introduced a useful SQL improvement which is the ability to use a VALUES(…) clause as an inline table within a query. The problem You need a small, hardcoded set of rows, a handful of status codes, a reference list or some test data and ideally without creating a temporary table or a view so […]

Go with Oracle Database – SQL Queries

This post will demonstrate how to connect to an Oracle database from Go using the Go DRiver for ORacle (godror) and execute SQL Queries. The code in this post is up on GitHub and was developed using Go 1.20.6 & VS Code running on Windows 10. I used a local version of the Oracle Database […]

SQLDeveloper: Exporting query results as CSV

This post will show you how to use the SQLFORMAT command from SQL Developer to transform a query output to CSV. Out of the box CSV Enter the following into SQL Developer, I am using SQL Developer version 18.1 and execute it as a script by pressing F5. and here is the output: “EMPLOYEE_ID”,”LAST_NAME”,”SALARY” 198,”OConnell”,2600 199,”Grant”,2600 […]

Using INSERT ALL with related tables

In this article I will demonstrate a method where the INSERTALL statement can be used to insert rows into two tables that are related by a foreign key constraint. The following example was developed and tested using the Pre-Built Oracle Database App Development VM which at the time of this post used Oracle Database 12.1.0.2.0  & SQL […]

No surprises with Oracle 12c Identity Column performance

Oracle 12c introduced the Identity Column. You can find out more about this feature in the new features guide and within the CREATE TABLE documentation. In this article I will use Tom Kyte’s run stats utility to compare the performance of the IDENTITY column with the explicit use of a sequence object. The script below will be used to […]