Go Premium for a chance to win a PS4. Enter to Win

x
?
Solved

sql request

Posted on 2014-04-29
7
Medium Priority
?
264 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 2000 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 78

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
Concerto Cloud for Software Providers & ISVs

Can Concerto Cloud Services help you focus on evolving your application offerings, while delivering the best cloud experience to your customers? From DevOps to revenue models and customer support, the answer is yes!

Learn how Concerto can help you.

 
LVL 78

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 78

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

Free Tool: IP Lookup

Get more info about an IP address or domain name, such as organization, abuse contacts and geolocation.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

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

Working with Network Access Control Lists in Oracle 11g (part 1) Part 2: http://www.e-e.com/A_9074.html So, you upgraded to a shiny new 11g database and all of a sudden every program that used UTL_MAIL, UTL_SMTP, UTL_TCP, UTL_HTTP or any oth…
Checking the Alert Log in AWS RDS Oracle can be a pain through their user interface.  I made a script to download the Alert Log, look for errors, and email me the trace files.  In this article I'll describe what I did and share my script.
This video shows how to Export data from an Oracle database using the Original Export Utility.  The corresponding Import utility, which works the same way is referenced, but not demonstrated.
Via a live example, show how to restore a database from backup after a simulated disk failure using RMAN.
Suggested Courses

783 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