All Forums Tools
new911 9 posts Joined 05/07
22 Jun 2007
BTEQ logon

Hi!I have a question regarding BTEQ.Let's say I am trying to logon.logon hostname/myuid,mypassit fails.Then I do the following.logon hostname/myuidit prompts me for passwordpassword:mypassSuccesfully logged on.When command, hostname and credentials are all in one line it failsWhen I do it interactively it is successful. Why is that?Thanks

Terrapin 1 post Joined 06/07
26 Jun 2007

Hi new911,I think the reason it failed was because it expects a semicolon after your password. If you add this it should be OK. When you go through the prompt route no such delimiter is required.try .logon hostname/myuid,mypass;RegardsTerrapin

new911 9 posts Joined 05/07
26 Jun 2007

IT does not help.I put semicolon at the end and it says*** Error: Invalid logon!*** Total elapsed time was 1 second.Teradata BTEQ 08.02.03.00 for WIN32. Enter your logon or BTEQ command:Then I enter it interactivelyand here you go*** Logon successfully completed.*** Transaction Semantics are BTET.*** Character Set Name is 'ASCII'.*** Total elapsed time was 5 seconds.BTEQ -- Enter your DBC/SQL request or BTEQ command:Do I need to set something on the server or client?

Fred 1096 posts Joined 08/04
26 Jun 2007

In "interactive mode" (standard input from terminal), BTEQ does not accept the password on the LOGON statement.In "batch mode" (standard input redirected from file), BTEQ requires the password on the LOGON statement.

new911 9 posts Joined 05/07
26 Jun 2007

Thank you for clarification.I moved one more step forward.Now I created batch file. I run the batch file from the location of COUNTRY.sqlbteq .logon tpcoe/UID,PASSW < COUNTRY.sql > COUNTRY.logit gave me whole bunch of errors. I had to set path inside the batch file otherwise it would not find bteq, then windcli32.dll and so on.I checked my env path and it contained the entries for teradata.So far everything works but I would like to know why it does not pick up env variables and I had to set it up in the batch file.Thank you all.

davidpracy 22 posts Joined 09/05
04 Jul 2007

create a 'logon' file called Example.logon that contains.logon system_DSN/user_name,password;call it in your bteq as follows:/* Example BTEQ */.Run file 'C:\script\logon\Example.logon';Exec Macro_Name;orCall SPROC_Name;or whatever you need to do..EXITHope this helpsdp

JohnBasha.N 1 post Joined 02/12
06 Feb 2012

i forget my Teradata BTEQ logon username and password how i recover it.

 

dnoeth 4628 posts Joined 11/04
07 Feb 2012

Ask your friendly DBA for your username and to reset the password.

Dieter

Dieter

You must sign in to leave a comment.