If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

 
Go Back  dBforums > Database Server Software > Informix > Dbaccess and Informix on AIX

Reply
 
LinkBack Thread Tools Display Modes
  #1 (permalink)  
Old 07-02-09, 17:35
dgirndt dgirndt is offline
Registered User
 
Join Date: Oct 2006
Posts: 2
Dbaccess and Informix on AIX

I am trying to pass parameter values in a dbaccess command line that will run a .sql file on an AIX platform running Informix Dynamic Srvr. 9.4.

dbaccess (database name) file.sql (what is the syntax to pass parameter values to -- file.sql ?

Thanx AOT
Reply With Quote
  #2 (permalink)  
Old 07-02-09, 18:06
bigcalm bigcalm is offline
Registered User
 
Join Date: Jul 2009
Posts: 37
You're probably better off doing a pre-process on your file using unix.

eg. let's say you have this in your original ' unload to /tmp/jon/x.unl select * from customers where creation_date >= :creation_date '

cat [original file] | sed 's/:creation_date/01-04-09/g' > /tmp/jon/tmp.sql

dbaccess dbname /tmp/jon/tmp.sql

rm -f /tmp/jon/tmp.sql
Reply With Quote
  #3 (permalink)  
Old 08-06-09, 03:11
ann1985 ann1985 is offline
Banned
 
Join Date: Aug 2009
Posts: 4
You're probably better off doing a pre-process on your file using unix.
Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On