TOAD Data Point views in Teradata?

Third Party Software
Enthusiast

TOAD Data Point views in Teradata?

Hello,

I am using TOAD Data Point as my access/query tool for my company's databases within the Teradata RDMS.  I have used the 'TOAD Views' functionality to create a VIEW to avoid having to re-write the SQL each time I want to use my more common queries.  My queries that I run straight from the 'SQL Editor' or the 'Query Builder' windows within TOAD run with no problems, but when I place the SQL within 'TOAD Views', I get the following error:

 

[Teradata Database] [3706] Syntax error: ORDER BY is not allowed in subqueries.

 

Here is the SQL I'm attempting to run (again, which runs fine from the 'SQL Editor' or the 'Query Builder' windows within TOAD:

select g.groupdn from ad_Grp g

left join ad_grp_member gm

on g.groupdn=gm.groupdn and g.as_of_dt=gm.as_of_dt

where gm.groupdn is null

and g.as_of_dt='2017-03-02 00:00:00'

and g.groupdn like '%DC=ABCDomain%'

order by 1

 

Why won't this simple SQL statement run from within the 'TOAD Views' functionality as it accesses my Teradata RDMS?

 

Thank you!

 

Tags (2)

Accepted Solutions
Highlighted
Teradata Employee

Re: TOAD Data Point views in Teradata?

Yes. Running the query is fine - ORDER BY is allowed when running the query. It is not allowed in the view.

1 ACCEPTED SOLUTION
4 REPLIES
Teradata Employee

Re: TOAD Data Point views in Teradata?

ORDER BY is not allowed in Teradata views.

Enthusiast

Re: TOAD Data Point views in Teradata?


ToddAWalter wrote:

ORDER BY is not allowed in Teradata views.


Hi Todd - I have read about that restriction in other postings, but I am able to run the above query successfully from the 'Query Editor/Builder'.  Does that make sense?

Highlighted
Teradata Employee

Re: TOAD Data Point views in Teradata?

Yes. Running the query is fine - ORDER BY is allowed when running the query. It is not allowed in the view.

Enthusiast

Re: TOAD Data Point views in Teradata?


ToddAWalter wrote:

ORDER BY is not allowed in Teradata views.


OK - thank you for the clarification... much appreciated!