Take the 2-minute tour ×
Database Administrators Stack Exchange is a question and answer site for database professionals who wish to improve their database skills and learn from others in the community. It's 100% free, no registration required.

I got into a weird SQL query-patch which looks for @ . and public keywords. I was wondering what is the purpose of these operators/keywords?

I suspect that it might be looking for SQL injection or some weird buffer overflow but I can't seem to understand why it looks for those characters, etc, and I can't find much information about those keywords.

If anyone could enlighten my eyes, it will be very helpful.

share|improve this question
3  
I'm really not sure what you are asking here - public as in create public synonym @ as in dblinks and . as in schema qualifier? Perhaps post some of the SQL? –  Jack Douglas Nov 2 '11 at 17:31
    
Hi, it is not exactly a query but an external function (written in c, no src though) which looks for them and throws an exception if anything is found. The function basically checks whether or not you have the correct privileges to access an object and how (select, update , etc). I do not know what is the purpose of those chars, and I couldn't find much information about the dot and the @ sign, I was wondering if you could enlighten me with usage of these operators. –  42_ Nov 3 '11 at 8:15
add comment

1 Answer

This diagram is from the Oracle Docs Syntax for Schema Objects and Parts in SQL Statements page:

general syntax for referring to an object or a part

It shows the general use of the period character (.) for qualification and the @ symbol for referencing dblinks.

The @ symbol is also used when creating dblinks.

Given that the public keyword is also used for creating them, I think it is likely that your external function is doing something with dblinks!

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.