Sponsored Content
Special Forums IP Networking how you connect to a database Post 81947 by matrixmadhan on Thursday 25th of August 2005 10:57:31 AM
Old 08-25-2005
i believe your question is how to connect to informix database.

it can be done in many ways.

let me explain the two ways.
if u are using dbaccess tool.

you can connect by

dbaccess <dbname@serverinstance> - <<EOF 2> <someerror.log>
select data1, data2 from <tb1>;
EOF


if u r connecting through program
prepare the statements
EXEC SQL prepare selSTMT from 'select data1, data2 from <tb1>;

and then execute the statement as
EXEC SQL execute selSTMT into :var1, :var2;

now the selected values would be in the two var1, var2 host variables.

I have not explained in detail as i am not clear with your requirement.
Please let me know if you have any more questions.
 

10 More Discussions You Might Find Interesting

1. Programming

¿how can I connect C to a database?

hi, please, help me i need connect my program in C whit a SybaseIQ 12 database i´m programming in solaris 5 (unix) please, help me, because i don`t know what to do... thanks.. jonathan (0 Replies)
Discussion started by: DebianJ
0 Replies

2. Shell Programming and Scripting

Can i connect from a .sh or .sc to a database?

please, help me-.... i need connect to a database Sybase IQ 12 and I don't know if i can do it using a shell program. if it's posibble, please tell me how... please, help me, because I don't know what to do.... thanks... jonathan (1 Reply)
Discussion started by: DebianJ
1 Replies

3. Programming

How to connect database in TC

Anybody please help me how connect a database file in TC for windows. regards Senthil. K (5 Replies)
Discussion started by: Senthil
5 Replies

4. Shell Programming and Scripting

Script to connect to As400 database

Hi, could you please help me out what are the command line commands to connect to as400. Thanks, (0 Replies)
Discussion started by: mgirinath
0 Replies

5. Windows & DOS: Issues & Discussions

how to connect to sybase database?

hi, I'd like to connect to a Sybase ASE 12 through a a graphic user interface (GUI) that run on windows and solaris10, because i need to do some querys. The database is running on solaris 10. I'm not an expert using databases, but i know how to use some SQL commands through command line... (3 Replies)
Discussion started by: danin
3 Replies

6. Shell Programming and Scripting

How to connect with oracle database using unix...

Hi all I am working in datawarehouse project and use DB2 database . shell scripting is written to connect with DB2 database in my application but i dont know how to connect with oracle databse or other databases.Is there any command in unix to connect any of these datbases? (6 Replies)
Discussion started by: vijays3
6 Replies

7. UNIX for Dummies Questions & Answers

Connect MySQL database from Unix

How to connect a MySQL database from unix using unix shell scripting ( people are using perl scrpt to connect the same database). I want to access a MySQL database through a shell script (4 Replies)
Discussion started by: apsprabhu
4 Replies

8. Shell Programming and Scripting

Connect to database from different unix box

Hi Friends, I have a one unix box "x.y.z" on SunOS , where oracle is not installed. And another machine "a.b.c" on AIX , where oracle is installed. Now i want to make a script on x.y.z , that can connect to database on a.b.c, using sqlplus command. and then generate a report based on the... (5 Replies)
Discussion started by: gauravgarg
5 Replies

9. Shell Programming and Scripting

Connect to Oracle database

could someone please help me in shell scripting. i want to connect to oracle database which is on remote sever. requirement: 1 want to check files in source directory if file exist then a execute a corresponding batch jobs on unix sever and fetch data from oracle database which is on remote... (2 Replies)
Discussion started by: refi123
2 Replies

10. Shell Programming and Scripting

Connect to database with shell output

Dear All, I am trying to write a script which will generate output to a file based on input files on basis of a pattern which I am able to do so. But, I am stuck as I am trying to connect this to database server. Below is my command and output details. Input Code filedate=$(date... (6 Replies)
Discussion started by: grvk101
6 Replies
NUTOP(8)																  NUTOP(8)

NAME
nutop - display top NUFW Users SYNOPSIS
nutop [ -help ] [ -c config file ] [ -delay refresh delay (seconds) ] [ -line number of lines to display ] [ -databasetype mysql/pgsql ] [ -host db host ] [ -user db username ] [ -pass db password ] [ -databasename db database name ] [ -tablename db table ] [ -port db port ] DESCRIPTION
This manual page documents the nutop command. Nutop is to be used by administrators willing to view users activity on a NuFW server, in real time. The display is designed to look a lot like the well known top command, as far as general layout is concerned. The default configuration file (containing SQL connections parameters) is located at /etc/nufw/nutop.conf. If decided to customize it to their needs, care should be taken about file permissions on that file, as it might let any user of the system access to the NuFW connection tracking database. Original packaging and informations and help can be found from http://www.nufw.org/ OPTIONS
-help Issues usage details and exits. -c config file Specifies config file to read SQL parameters from. Default is /etc/nufw/nutop.conf -delay number Specifies a rate to refresh display. This parameter is interpeted as a number of seconds. Default is 2s. -line number Number of lines to display. Default : 20 -databasetype mysql/pgsql Type of database to connect to. Default is mysql. This setting also sets the default port setting. -host hostname/IP IP address or FQDN of database we connect to. Default value : 127.0.0.1 -user username Database username to connect as. Default is "nutop" -pass password Password to use to connect to database. -databasename name of database Name of database we connect to. Default is "nulog" -tablename name of table Name of SQL table to use for queries. Default is "ulog" -port TCP port TCP numeric port to use for database connection. Default is 3306 if databasetype is mysql, 5432 if pgsql. SEE ALSO
nuauth(8), nufw(8) AUTHOR
Nufw was designed and coded by Eric Leblond, aka Regit (<eric@inl.fr>) , and Vincent Deffontaines, aka gryzor (<vincent@inl.fr>). Original idea in 2001, while working on NSM Ldap support. This manual page was written by Vincent Deffontaines Permission is granted to copy, distribute and/or modify this document under the terms of the GNU Free Documentation License, Version 2 as published by the Free Software Foundation; with no Invariant Sections, no Front-Cover Texts and no Back-Cover Texts. 18 mars 2007 NUTOP(8)
All times are GMT -4. The time now is 07:17 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy