All Forums Database
22 Apr 2009
setting up hosts file entries in such a way to avoid giving TPID in BTEQ scripts

Hi all,There are teradata databases(DEV, PROD) running on two different nodes with two different ipaddresses.I need to execute my BTEQ,Fload scripts from one appnode(a.b.c.d).in a.b.c.d appnode i've given the hosts file entries like this#prod entries1.2.3.4 xxxxxx prodcop1 dbccop1 xxxxxy prodcop2 dbccop2#dev3.4.5.6 qqqqq devcop1 dbccop3in my odbc.ini file i've given entries like this:[dev]DSNTraceEnable=NODriver=/usr/odbc/drivers/ tdata.soDescription=NCR 3600 running Teradata V1R5.2DBCName= LastUser=Username=Password=Database=DefaultDatabase=de vdataIf I try to run the bteq scripts on appnode i'm getting following error *** Error 3004 User identification is not authorized. *** Error: Logon failed!I'm not specifying my TPId at the script level.likebteq.logon username,passwd;select * from emp;.quit;and I do not want to specify TP Id explicitly at the script level due to security reasons.can you suggest a solution for the above problem..Thanks Raj

Fred 1096 posts Joined 08/04
22 Apr 2009

I find it odd that you mention inclusion of TDPID as a security issue but you're OK with including username and password both in clear text.BTEQ uses CLI so ignores odbc.ini. And you should never specify the same TDPID prefix (dbc in your example) for multiple systems in /etc/hosts entries.But to answer your question, you can have multiple clispb.dat files, each with a different value for default i_dbcpath (prod and dev, in your example, instead of dbc). Change the COPLIB environment variable to specify the path in which the appropriate clispb.dat can be found, before you invoke BTEQ.

You must sign in to leave a comment.