473,396 Members | 1,827 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,396 software developers and data experts.

how to save operators in the database

omerbutt
638 512MB
hi i have an applicationa for online test in there i have to save some questions in the db now when i try to save this question
what is 2 + 2 ?

when i save it in the database it removes the + sign and replaces it with a white space
any help in this
regards,
Omer Aslam
Aug 24 '09 #1
7 1658
Dheeraj Joshi
1,123 Expert 1GB
Whether "what is 2+2" is a string?

I mean have given it as varchar in database???

Your query can be like this.. "what is2"+"+"+"2?"..........

Regards
Dheeraj Joshi
Aug 24 '09 #2
Dheeraj Joshi
1,123 Expert 1GB
I think above query works..

Just try....

Regards
Dheeraj Joshi
Aug 24 '09 #3
Markus
6,050 Expert 4TB
@omerbutt
That doesn't sound right - what database are you using? What's the table set-up? What's your SQL look like? How does the PHP look?

Mark.
Aug 24 '09 #4
omerbutt
638 512MB
@Markus
icurrently have
MySQL client version: 5.0.51a
Apache/2.2.11
PHP Version 5.2.9

the database engine i am using is MYISAM
The table has a field name question title that is VARCHAR (255) and i am trying to save in that field
regards,
Omer Aslam
Aug 25 '09 #5
Markus
6,050 Expert 4TB
The SQL? The PHP? Going to have to see it if we're to make an informed answer.
Aug 25 '09 #6
hsriat
1,654 Expert 1GB
This doesn't seem like a PHP or MySQL problem, but there's some URI encoding problem.

Somewhere in the process, probable when submitting this string from front end to php, you are skipping URI encoding.
Aug 31 '09 #7
Dheeraj Joshi
1,123 Expert 1GB
Does the problem still persist?

Is it only with + symbol? or with any mathematical symbols like - * / % ^ etc etc?

Regards
Dheeraj Joshi
Aug 31 '09 #8

Sign in to post your reply or Sign up for a free account.

Similar topics

4
by: Andras Gilicz | last post by:
Hi VB fans I'm working on a relatively large project in VB6 with about a dozen forms, including graphs, labels, text boxes, etc. The software itself is actually a flow simulator with more or...
14
by: greg | last post by:
Discussion is invited on the following proto-PEP. ------------------------------------------------------------- PEP ??? - Overloadable Boolean Operators...
205
by: Jeremy Siek | last post by:
CALL FOR PAPERS/PARTICIPATION C++, Boost, and the Future of C++ Libraries Workshop at OOPSLA October 24-28, 2004 Vancouver, British Columbia, Canada http://tinyurl.com/4n5pf Submissions
1
by: Thats Me | last post by:
TMALSS: Task With maintenance of Access Database I did not develop, don't ask about non-commented code problems or where data dictionary is (LOL). Have table with Inventory data for all...
7
by: Shanli RICHEZ | last post by:
I'm using ASP.NET and quite a lot of object in memory instead of a database. The question is that I tried to save the data, serialize them in a XML file to save them when the application is...
4
by: xAvailx | last post by:
Hello: I didn't find any documentation that notes save point names are case sensitive, but I guess they are... Stored Proc to reproduce: /* START CODE SNIPPET */ If Exists (Select * From...
9
by: =?Utf-8?B?QmVu?= | last post by:
Hi, I'm trying to figure out the purpose of these operators. Now, I know what they do. They shift bits either left or right. But I don't know why would anybody want to do that. I've never seen...
6
by: Josetta | last post by:
Access 2003 I've been experiencing some problems with my "monster" database the last couple of days. I imported all objects into a new database yesterday, which pretty much stopped the crashing...
0
by: aj | last post by:
SQL Server 2005 SP2 64-bit I am quite confused about the SQL Server Agent Alert System. I have configured Database Mail, establishing my Profile(s) and Account(s), and specifying SMTP...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.