How Do You Troubleshoot the Oracle and Java Message “java.sql.sqlexception ora-01003 no statement parsed”?

Problem scenario
You run a Java program that runs a SQL statement in an Oracle database.  You get this error: “java.sql.sqlexception ora-01003 no statement parsed”.  What do you do to fix this?

Solution
Run the Java program a second time.  Does the problem remain?  It could be that there was a successful DDL command, and this error could be ignorable.  

You may want to try these links for further info:
https://stackoverflow.com/questions/23866710/ora-01003-no-statement-parsed
https://community.oracle.com/thread/736289 (this link used to work)

How Do You Use Encapsulation in Python?

Problem scenario
You know about encapsulation.  You know about private methods that are only accessible from inside a class — not outside.  You want to encapsulate a method in a class in Python.  How do you write such a program?

Solution
“Programmers are most effective if shielded from, not exposed to, the innards of modules not their own.” (This was taken from page 272 of The Mythical Man-Month.)

Here is an example;

How Do You Troubleshoot JIRA Not Working due to Not Finding a Suitable Driver?

Problem scenario
Atlassian JIRA is not working.  The web UI does not have a login page.  On the back-end in the logs, you see an error about not finding a suitable driver.  (You may get an error about a port number instead.  This problem may require a similar solution to the one proposed below for an error about a suitable driver.)  You know you have the ojdbc.jar file (or variation thereof) in the correct place. 

With awk, What Do You Do to Get a Colon To Be Recognized as a Separator of Fields?

Problem scenario
You have Awk 4.1.3 installed.  The default field separator in awk is a space.  You want to assign it to a different character — specifically a colon “:”.  You have a string with a colon assigned to the variable “y”.  You have tried these things:

echo $y | awk -F “:” ‘/1/ {print $NF}’  # this prints nothing
echo $y | awk ‘{FS=”:”;

How Do You Write a Java Program to Accept a Number for the Command Terminal and Print It Back Out?

Problem scenario
You want to write a basic Java program to test it out.  How do you write a program to accept user input, specifically a number, and print it back to the screen (using the integer data type)?

Solution
1.  Install the Java Development Kit if you have not installed it yet.  If you are not sure you have it, run javac -version

How Do You Use an USB-Connected Local Camera with Your Desktop Computer?

Problem Scenario
You purchased a camera that connects to your computer (e.g., a laptop) with a USB cable.  An example may be an SQ9* camera. You now want to use it.  The device connects to your laptop via a USB mini to USB A connector.  How do you view images on your desktop that are captured with the camera lense?

How Do You Access the SonarQube Web UI When It Is Only Listening on the 127.0.0.1 IP Address?

Problem scenario
SonarQube is listening on the loopback IP address on port 9000.  SonarQube is not listening on the external IP address.   You want to access the web UI for SonarQube. What should you do?

Solution
Install a web server and configure it to connect to port 9000.  Here are the details for using Apache web server on a Red Hat derivative (e.g., CentOS/RHEL/Fedora).

1. 

How Do You Create a .ppk File from a .pem File?

Problem Scenario
You want to use a key kair to log into AWS instances. You created an AWS EC-2 instance (aka a virtual machine or server) running Linux.  You want to connect to this Linux server (a VM).  You created a key pair when you created this VM.  You downloaded the .pem file.  You need a .ppk file to log in.  What should you do?

Solution
1. 

How Do You Troubleshoot “permission denied” when Trying to Clone a Git Repository That You Should Have Access to?

Problem scenario
You configured the source repository (in GitHub, GitLab, in BitBucket or elsewhere) to allow your user to have permissions to read the repository.  You run git clone but you get a “permission denied” error.  What should you do?  

Possible solutions
The Linux server you are on may not give your Linux user permissions to write to the destination directory.  Can you clone the repository to the /tmp/ directory? 

What Do You Do when an Ansible Playbook Is Not Removing a File or Directory or Unmounting a Directory when There Are No Errors?

Problem scenario
You run a playbook, and there are no errors.  But the playbook’s simple logic is not working.  The file or directory is not being eliminated.  Or the unmount of the directory is not working via the mount module.  What should you do about a silently failing playbook?

Solution
1.  Verify there are no [trailing] spaces in the directory path.