Can i set a paremeter ?
Posted in 1999
Topics: Server Administration
hello all
i have no much experience with informix SE 4.x
my question is :
i have an .sql file created with dbaccess with a instruction like :
select * from table001 where campo1 = "xxxx" and campo2 between "yyy"
and "zzz"
values "xxxx", "yyy" and "zzz" can be parameters ?
can i execute an instruction like : ?
# dbaccess datos file001.sql "xxx","yyy","zzz"
have i any way to do some like this ?
thanks to all of you.
________________________________________________________________
Para respuestas via e-mail quitar de la direcci'n "NOSPAM"
To answer via e-mail you must erase "NOSPAM" into e-mail address
fgomez@NOSPAMfreirehnos.es
fcojgome@NOSPAMworldonline.es
pako gomez <nostoy@latinmail.com> schrieb in im Newsbeitrag:
811iqg$1s3$1@diana.bcn.ttd.net...
> hello all
> i have no much experience with informix SE 4.x
>
> my question is :
> i have an .sql file created with dbaccess with a instruction like :
> select * from table001 where campo1 = "xxxx" and campo2 between "yyy"
> and "zzz">
> values "xxxx", "yyy" and "zzz" can be parameters ?
not that I know
>
> can i execute an instruction like : ?
> # dbaccess datos file001.sql "xxx","yyy","zzz">
> have i any way to do some like this ?
You could use dbaccess in a shell script, like:
dbaccess datos <<EOF
select * from table001 where campo1 = "${1}"
and campo2 between "${2}" and "${3}"EOF
>
> thanks to all of you.
>
> ________________________________________________________________
> Para respuestas via e-mail quitar de la direcci'n "NOSPAM"
> To answer via e-mail you must erase "NOSPAM" into e-mail address
> fgomez@NOSPAMfreirehnos.es
> fcojgome@NOSPAMworldonline.es
>
>
Christoph K'nzle <christoph.kuenzle@bluewin.ch> escribi' en el mensaje de
noticias 8121mr$2jm$1@bw107zhb.bluewin.ch...
> You could use dbaccess in a shell script, like:
> dbaccess datos <<EOF
> select * from table001 where campo1 = "${1}"
> and campo2 between "${2}" and "${3}"> EOF
thanks, i try it.