Generating JavaScript, Python, Java, and C# Data Access Code

You can generate JavaScript, Python, Java and C# code that can be built into an app that connects to Oracle Database or Oracle Autonomous Database and selects data from tables or views.

The generated code includes your actual connection string as well as instructions showing how to obtain the Oracle Database data access driver for the language being used.

  • To generate data access code, select one or more tables or views from the Database Explorer tree control. Right click and select Generate Code.

    A list of languages will pop up. Select the language you wish to generate the code for.

  • A new file editor will open with the generated code. Follow the instructions in the comments to install the required driver and build the application. Modify the connection string as needed (for example, to provide the password), and run the application.

  • Running the Generate Code command multiple times will use the originally selected language and will insert the newly generated code at the location of the cursor in the editor. To generate code for a different language than originally selected, close the file editor and try again.