Can i used DMLsentences in DS engine shell ?

A forum for discussing DataStage<sup>®</sup> basics. If you're not sure where your question goes, start here.

Moderators: chulett, rschirm, roy

Post Reply
alexcol
Participant
Posts: 17
Joined: Mon Feb 28, 2011 8:52 am

Can i used DMLsentences in DS engine shell ?

Post by alexcol »

good afternoon.

Now that i could connect to a Teradadata database using the information provided in the 3 mains files, i tried to run some selet staments but failed. for instance:

select P.pARTY_sTART_dT, count(*)
SQL+from DWH_DATA.INDIVIDUAL_NAME_HIST INH
SQL+inner join DWH_DATA.PARTY P
SQL+on INH.iNDIVIDUAL_pARTY_iD = P.PARTY_ID
SQL+and P.pARTY_sOURCE_CODE = 1 /* scl-usuario */
SQL+and P.pARTY_sTART_dT > '2010/11/30'
SQL+group by 1
SQL+ORDER BY 1
SQL+

DataStage/SQL: Table "DWH_DATA.INDIVIDUAL_NAME_HIST" does not exist

Running a simple select statement select * from table yiels the error that the table doesnt exist, even i f i run the whole shema file DATABASE.table

Id appreciate your help
ALEJO
ray.wurlod
Participant
Posts: 54607
Joined: Wed Oct 23, 2002 10:52 pm
Location: Sydney, Australia
Contact:

Post by ray.wurlod »

Short answer: No.

Teradata DML statements must be executed in a Teradata environment such as BTEQ. You can, of course, invoke that environment from the DataStage environment.
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
alexcol
Participant
Posts: 17
Joined: Mon Feb 28, 2011 8:52 am

Post by alexcol »

OK, thanks for your reply but with the sentence below why it yields the error message "the table doesnt exist?" , whats wrong with this sentence, or how can i move to the database where the table hosts and run the required select statement?
ALEJO
chulett
Charter Member
Charter Member
Posts: 43085
Joined: Tue Nov 12, 2002 4:34 pm
Location: Denver, CO

Post by chulett »

The table doesn't exist in the project you are connected to. And you can't move anywhere in there where it will find anything other than DataStage objects.
-craig

"You can never have too many knives" -- Logan Nine Fingers
ray.wurlod
Participant
Posts: 54607
Joined: Wed Oct 23, 2002 10:52 pm
Location: Sydney, Australia
Contact:

Post by ray.wurlod »

The DS shell is attempting to find a DataStage (UniVerse) table of that name. It doesn't exist.
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
Post Reply