Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7720933
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 1, 20262026-06-01T03:47:46+00:00 2026-06-01T03:47:46+00:00

For inserting special characters in data like (,’)etc., I am using mysql_real_escape_string() function &

  • 0

For inserting special characters in data like (,’)etc., I am using mysql_real_escape_string() function & it’s working fine.

Now I want to use same variable while inserting values in Oracle.

$str = 'N.G.Palace\'s Building',
    'xyzcity', '12345678','India','100001',12

Here $str is result of mysql_real_escape_string(). so it escapes special character.
Now my code for oracle is like this-:

 $qry ="INSERT INTO Ora_table(ship_to_street, ship_to_city,ship_to_country, ship_to_telephone, order_id, record_no) VALUES(".$str);

So my doubt is Oracle is not accepting values return by mysql_real_escape_string i.e. Palace\’s (like this as this mysql function attach \ before ‘single quote)?
So can anybody tell me ho9w can I use that variable $str to insert data into Oracle?

Also I tried like this also-:

"q"."'"."c".$str."c"."'"

can we use this for multiple values like in my case…though still I am unable
to inser data in oracle?

HOW to insert special characters in Oracle db?
like 'SWEET/HOME', 'CROY-BOY' etc. /,-,\ etc.

please tell me..

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-01T03:47:48+00:00Added an answer on June 1, 2026 at 3:47 am

    I strongly urge you not to build queries by appending strings together. This is a ticket straight to hell – or to SQL Injection City, which is one stop earlier. 🙂 Seriously, though, if you use parameter markers and bind the values to the parameter markers you gain a couple of advantages:

    1. You don’t have to escape anything, and
    2. No worries about SQL injection.

    Share and enjoy.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I am using mysql_real_escape_string function while inserting the data into MySQL database. I am
I need to join random special characters (!,@,#,$,%,^,&,*) to my string which looks like:
i have field in databaase. which contains special characters. i want to escape these
I am loading and inserting data into an Oracle database. When I encounter special
I am having an issue with inserting words with special characters into my database.
When is it necessary to escape double quotes and/or special characters when inserting into
Before inserting data to the database, I encrypted the user name and password like
Inserting rows one by one from a 600 record data-set is taking almost an
Basically I am inserting an image using the listviews inserting event, trying to resize
I'm inserting something in the cache when the user does a login. Now I

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.