Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Westi on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Handling With Special Characters

Status
Not open for further replies.

fox12

Programmer
Jan 18, 2005
62
US
I have a report with asking a user to select a project name first before retrieving data. I set all the default values of the project in the parameter fields. However, if the project name contains a character like "-", the report returns no records (which should actually returns a few). Definitely, the dash "-" is a troublemaker. While it is not very convenient to ask a user to enter a project name without a dash, is there a way in Crystal Report which can handle these special characters without worrying whether the characters are valid or not? How?

Thanks very much.

Fox12
 
Dashes don't cause Crystal any problems.

Solutions vary based on the environment, so post technical information, it's much more useful than a text description:

Crystal version
Database/connectivity used
Example data
Expected output
Your current Report->Edit Selection Formula->Record

-k
 
I am using Oracle 9i as DB and ODBC connection. An example data would look like:
project name: India Geological Team-9 (bad/not working)
project name: Japan Geological Team_10 (good/work)

ID, ProjectName, Payment, PayDate
1, India Geological Team-9, $32,234, 05/01/05
2, Japan Geological Team_10, $33,234, 05/01/05
3, Germany Economic Team, $34,234, 05/01/05
4, US Research Team, $35,234, 05/01/05

It is expected that that the query will return the first row when the parameter value is "India Geological Team-9". Unfortunately, it return null.

Any idea?

Fox12
 
Which ODBC are you using, the Oracle supplied, or the Crystal supplied Oracle driver?

If you're going to use the inferior ODBC type of connectivity, make sure that you use the Crystal supplied driver, but native is much faster.

I suspect that it's either driver related, or you need to update your parameter list because something has changed.

-k
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top