Solved

sql request

Posted on 2014-04-29
7
253 Views
Last Modified: 2014-05-20
How we will full fill this
if my sql query is
select * from emp;

select /* 10046 */ .. / <<-- to complete with your sql request


Please help me to fullfil the query with out syntax error.
0
Comment
Question by:vangogpeter
  • 3
  • 2
  • 2
7 Comments
 
LVL 4

Accepted Solution

by:
Alex Matzinger earned 500 total points
ID: 40030840
Not sure what you're asking for...

if thats a comment:

select /* 10046 */ *
from emp;

Open in new window


if you're asking for all values like 10046?

select *
from emp
where value like ('%10046%');

Open in new window

0
 
LVL 76

Expert Comment

by:slightwv (䄆 Netminder)
ID: 40030851
I believe Alex has the correct syntax in his first code example.

My guess is this is related question when you are trying to trace a SQL statement and are looking to add a comment to it so you can find it in the trace file.

Personally I would add a more descriptive comment other than the event number I am tracing.
0
 

Author Comment

by:vangogpeter
ID: 40030859
I made an error in the request
this is my sql request not select * from emp;

SELECT sys_user0."name"
FROM PREMDEV_ADMIN.sys_user sys_user0
WHERE (lower(sys_user0."name") LIKE lower('WU%') ESCAPE '\') OR (lower(sys_user0."email") LIKE lower('WU%') ESCAPE '\')
AND (sys_user0."active" = 1)
ORDER BY sys_user0."name";



select /* 10046 */ .. / <<-- to complete with your sql request

 { i got this from online just a help to how to apply this}


Please help me to fullfil the query with out syntax error.
0
PRTG Network Monitor: Intuitive Network Monitoring

Network Monitoring is essential to ensure that computer systems and network devices are running. Use PRTG to monitor LANs, servers, websites, applications and devices, bandwidth, virtual environments, remote systems, IoT, and many more. PRTG is easy to set up & use.

 
LVL 76

Expert Comment

by:slightwv (䄆 Netminder)
ID: 40030861
>>select /* 10046 */ .. / <<-- to complete with your sql request

Sorry but I have no idea what this means.

Can you provide the link where you found this?
0
 
LVL 4

Expert Comment

by:Alex Matzinger
ID: 40030866
It'd be the same thing:
SELECT /* 10046 <more description to this comment> */sys_user0."name"
FROM PREMDEV_ADMIN.sys_user sys_user0
WHERE (lower(sys_user0."name") LIKE lower('WU%') ESCAPE '\') OR (lower(sys_user0."email") LIKE lower('WU%') ESCAPE '\')
AND (sys_user0."active" = 1)
ORDER BY sys_user0."name"; 

Open in new window

0
 

Author Comment

by:vangogpeter
ID: 40030870
No it is printed out no link.
0
 
LVL 76

Expert Comment

by:slightwv (䄆 Netminder)
ID: 40030904
>>No it is printed out no link.

Then we need to know what it is supposed to do for you.

Again, if it is just a comment in a statement to track it in a trace file, add a descriptive comment to the select as previously posted.

If it means something else, then you need to explain to us what it is supposed to do.
0

Featured Post

PRTG Network Monitor: Intuitive Network Monitoring

Network Monitoring is essential to ensure that computer systems and network devices are running. Use PRTG to monitor LANs, servers, websites, applications and devices, bandwidth, virtual environments, remote systems, IoT, and many more. PRTG is easy to set up & use.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Why doesn't the Oracle optimizer use my index? Querying too much data Most Oracle developers know that an index is useful when you can use it to restrict your result set to a small number of the total rows in a table. So, the obvious side…
Subquery in Oracle: Sub queries are one of advance queries in oracle. Types of advance queries: •      Sub Queries •      Hierarchical Queries •      Set Operators Sub queries are know as the query called from another query or another subquery. It can …
Video by: Steve
Using examples as well as descriptions, step through each of the common simple join types, explaining differences in syntax, differences in expected outputs and showing how the queries run along with the actual outputs based upon a simple set of dem…
This video shows how to configure and send email from and Oracle database using both UTL_SMTP and UTL_MAIL, as well as comparing UTL_SMTP to a manual SMTP conversation with a mail server.

919 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

18 Experts available now in Live!

Get 1:1 Help Now