Go Premium for a chance to win a PS4. Enter to Win

x
?
Solved

Username and password issue in Unix

Posted on 2009-05-05
1
Medium Priority
?
417 Views
Last Modified: 2012-05-06
Hello. I have a .SQL file named employee.sql which contains the statement below :-

load from '/use/local/bin/name.csv' delimiter ',';
insert into employee_access

My only question is how to define the JDBC url with username and password in unix script ? I know it can be done in perl but was wondering if it is possible to be done in a korn shell ?.
If i know how to define my JDBC connection info with username and password i can execute this statement in my script which will insert all the values from the CSV file :-

dbaccess employees < employee.sql
0
Comment
Question by:Micheal_Male
1 Comment
 
LVL 51

Accepted Solution

by:
ahoffmann earned 375 total points
ID: 24313717
each database comes with a client program, such as plsql for Oracle, mysql for MySQL and so on ...
You need to use that client program and pass the proper database, table, username and password. The syntax of these command line arguments is different for each, check your man pages.
0

Featured Post

Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Attention: This article will no longer be maintained. If you have any questions, please feel free to mail me. jgh@FreeBSD.org Please see http://www.freebsd.org/doc/en_US.ISO8859-1/articles/freebsd-update-server/ for the updated article. It is avail…
When you do backups in the Solaris Operating System, the file system must be inactive. Otherwise, the output may be inconsistent. A file system is inactive when it's unmounted or it's write-locked by the operating system. Although the fssnap utility…
Learn several ways to interact with files and get file information from the bash shell. ls lists the contents of a directory: Using the -a flag displays hidden files: Using the -l flag formats the output in a long list: The file command gives us mor…
Learn how to navigate the file tree with the shell. Use pwd to print the current working directory: Use ls to list a directory's contents: Use cd to change to a new directory: Use wildcards instead of typing out long directory names: Use ../ to move…
Suggested Courses
Course of the Month11 days, 8 hours left to enroll

916 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question