HPE GreenLake Administration
- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- Re: Using DERIVED TABLES with SELECT
Operating System - HP-UX
1834417
Members
1738
Online
110067
Solutions
Forums
Categories
Company
Local Language
back
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Forums
Discussions
Discussions
Discussions
Forums
Discussions
back
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Blogs
Information
Community
Resources
Community Language
Language
Forums
Blogs
Topic Options
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-15-2003 12:12 PM
05-15-2003 12:12 PM
Using DERIVED TABLES with SELECT
I am having problems retrieving information using SELECT from derived tables. Here's an example of the code:
SELECT. FROM (select FROM )
e.g.
1) SELECT DISTINCT n.pk_node, RTRIM(n.corp_name) + '/' + RTRIM(n.name) AS 'name'
FROM
(
SELECT s.pk_node
FROM service s
JOIN requestor_to_service rs ON s.dts_resp_id = rs.dts_resp_id
JOIN node n ON n.pk_node = rs.pk_node
AND n.ext_node_info LIKE @ext_node_info + '%'
) t
JOIN node n ON t.pk_node = n.pk_node
2) select t.num from (select num=1) t
I get the error: Incorrect syntax near the keyword SELECT
Kindly advice. I am converting from SQL Server to Sybase. This wasn't an issue in SQL Server.
SELECT
e.g.
1) SELECT DISTINCT n.pk_node, RTRIM(n.corp_name) + '/' + RTRIM(n.name) AS 'name'
FROM
(
SELECT s.pk_node
FROM service s
JOIN requestor_to_service rs ON s.dts_resp_id = rs.dts_resp_id
JOIN node n ON n.pk_node = rs.pk_node
AND n.ext_node_info LIKE @ext_node_info + '%'
) t
JOIN node n ON t.pk_node = n.pk_node
2) select t.num from (select num=1) t
I get the error: Incorrect syntax near the keyword SELECT
Kindly advice. I am converting from SQL Server to Sybase. This wasn't an issue in SQL Server.
2 REPLIES 2
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-15-2003 12:24 PM
05-15-2003 12:24 PM
Re: Using DERIVED TABLES with SELECT
hi,
2.
"select num=1" does not seem to be correct hence the syntax error.
i guess it should be "select from "
what is the error for case 1?
revert
Yogeeraj
2.
"select num=1" does not seem to be correct hence the syntax error.
i guess it should be "select
what is the error for case 1?
revert
Yogeeraj
No person was ever honoured for what he received. Honour has been the reward for what he gave (clavin coolidge)
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-15-2003 12:35 PM
05-15-2003 12:35 PM
Re: Using DERIVED TABLES with SELECT
Hi Yogeeraj,
Thanks but you didn't get my problem properly. The second SQL was just a simplified form of the use of derived tables for my cause. That doesn't exist for me in the real sense.
Anyway, that query is fine as per SQL Server syntax. I am facing problems using derived tables instead of actual tables after the 'FROM' clause. SQL Server allows that. Sybase is giving me a no-no.
Kindly advice.
Revert.
Prandip
Thanks but you didn't get my problem properly. The second SQL was just a simplified form of the use of derived tables for my cause. That doesn't exist for me in the real sense.
Anyway, that query is fine as per SQL Server syntax. I am facing problems using derived tables instead of actual tables after the 'FROM' clause. SQL Server allows that. Sybase is giving me a no-no.
Kindly advice.
Revert.
Prandip
The opinions expressed above are the personal opinions of the authors, not of Hewlett Packard Enterprise. By using this site, you accept the Terms of Use and Rules of Participation.
Company
Events and news
Customer resources
© Copyright 2025 Hewlett Packard Enterprise Development LP