Sitemap

Amicuk Programming Answers

Report handling names with a single quote

2015-10-11   Views:0

Advertisement

Report 10gR2 I have created a report and most of the functionality that i want is working as expected. I have a report where i am letting user enter their first name on one field and last name on another field in the parameter screen ( thats how it's

Report 10gR2
I have created a report and most of the functionality that i want is working as expected.
I have a report where i am letting user enter their first name on one field and last name on another field in the parameter screen ( thats how it's stored in the database)
If they enter any name with an aphostrophe , say D'Costa ( either first name or last name)
then i get the below error
REP-50003: Bad parameter: pfaction=http://.........
I am using like keyword as seen below in the afterparam trigger and passing the parameter :p_where_last_name to the main sql query
     :p_where_last_name := ' AND UPPER( :last_name) LIKE (' ||''''||'%'||UPPER(:last_name)||'%'||''''||')' ;
Whats the best approach to handle this issue
Also is there a way to capture this error
' REP-50003: Bad parameter: pfaction=http://.........
' and display a message, if so where and how, please advise.
thanks.
Edited by: Forms_Reports_Beginner on Aug 13, 2009 1:52 PM

The replay answer
Advertisement
I am not using form , it's just done in report, that is i am not calling the report from a form , just from a menu.
:last_name is a report_paramter that i created on the report.
you're right the first assignmnt is
AND UPPER( db column) LIKE
I have a paramter form on the report with a field last name and I am letting the user enter last name there which gets stored in the :last_name
Edited by: Forms_Reports_Beginner on Aug 14, 2009 7:29 AM
Edited by: Forms_Reports_Beginner on Aug 14, 2009 7:32 AM
Rodolfo,
your solution works,
:p_where_clause := ' AND UPPER( db_column ) LIKE (' ||''''||'%'||UPPER(Replace(:p_2,chr(39), chr(39)||chr(39)))||'%'||''''||')' ;
but i dont quite understand how this is working
Replace(:p_2,chr(39), chr(39)||chr(39))
i have never used chr
Edited by: Forms_Reports_Beginner on Aug 14, 2009 7:35 AM

Go to See the other 7 answers

Report handling names with a single quote

Category:DefaultRelease time:2015-10-11Views:130

Report 10gR2 I have created a report and most of the functionality that i want is working as expected. I have a report where i am letting user enter their first name on one field and last name on another field in the parameter screen ( thats how it's[More]

How to handle XML string with Single Quotes as a parameter to SP dynamically?

Category:DefaultRelease time:-0001-11-30Views:130

Hi, I would like to know if there is a way to handle the Single Quotes in XML value when it is passed to Stored Procedure? I should be able to handle it without adding another Single Quote to it. Thanks, Chandra ShekarHi Chandra, Your requirement is[More]

SSAS SSRS Report Action on Cell Value w/ Embedded Single Quote Not Executing

Category:DefaultRelease time:2015-10-11Views:130

I have configured an SSAS 2008 R2 cube SSRS ReportAction. I'm having problems when the member value for a cell has an embedded single quote, e.g. abc's. The action displays on the context menu appropriately, but when I click on the action, nothing ha[More]

Problem with lookup-table and single quotes

Category:DefaultRelease time:-0001-11-30Views:130

SOA Suite 10.1.3.3. I have an ESB project with an XSLT map that uses orcl:lookup-table to translate values. I use this instead of lookup-dvm because I want non-IT users to manage the mappings without having access to the ESB Console. According to the[More]

How can I will declare the symbol u2018 (Single Quote) in the report

Category:DefaultRelease time:2015-10-11Views:130

Hi , Could you please tell me how can I will declare the symbol u2018 (Single Quote) in the report. My requirement is that I have concate the data with single quote and after that I have to store the data in to an internal table and I have to downloa[More]

SSRS Report Returning Double Quote string from a Single Quote String

Category:DefaultRelease time:2015-10-11Views:130

Hi, I'm getting weird thing in resultset from SSRS report when executed. When I pass parameter to a report, which passes String that has single quote value to a split function , it returns rows with double quote.  For example  following string: 'N ga[More]

Report parameter field value has a single quote. need to escape before pass

Category:DefaultRelease time:2015-10-11Views:130

Report has a parameter whose value might have a single quote in it. If I pass that value directly into the SQL Command... like where ... user_name = {?parm_user_name}... which would translate to user_name='O'Donnel Honda' I am getting an error... so[More]

How to handle single quote between two single quotes in ABAP?

Category:DefaultRelease time:2015-10-11Views:130

Dear SAP Gurus I have a question regarding handling a string data. Say I have a string  ABCD'\&%$!!ABC'AAA123.   Please notice that there are single quotes in my string. I am writing a parser code in ABAP and getting into problem with if statement to[More]

Unable to pass parameters in Report Bulder due to single quotes

Category:DefaultRelease time:-0001-11-30Views:130

Hello, I have a problem with parameters in Report Bulder. This is the query: where task.closed_at between (@Per) Then I need have to pass following value to @Per : DATEADD(month, -5, getdate()) and getdate() to get following: where task.closed_at bet[More]

Passing single quotes in a lexical parameter from forms11g to reports 11g

Category:DefaultRelease time:-0001-11-30Views:130

Hi, We've upgraded our forms and reports from 10.1.2.3 to 11.1.2.1 and this has broken a number of reports where we pass a string of single quoted variables to reports as a lexical parameter. v_string := ''''||:block.item1||''''||','||''''||:block.it[More]

Handling single quote

Category:DefaultRelease time:2015-10-11Views:130

I have a custom function in which I want to parse out any single quotes as they are causing problems further down in our process. Actually what I want the function to do is to find the first single quote, if it exists, then strip the single quote and[More]

Hot
Hi. This is possible a very trivial question and something which is very easy to do however I am new to MacBooks and so am unsure of exactly what to do. I have an iPhone 4 and have just purchased a MacBook Pro today. I would like to sync the two prod [More]
Hello. I am trying to clear all the data from a file that will be continually replaced with a file of the same name with new data in it.  The goal is to delete the file while going through a while loop.  The problem I am having is with a dialog box p [More]
Windows failed to start error I am running a Compaq mini 110c netbook and the following error message occurred on start up. The netbook does not have a slot for a disc as everything was in the netbook already. I am a complete technophobe and need hel [More]
Hi, A few things. This may be a mix of builder and sdk. I read that 4.5.1 Flex Mobile automatically used AIR 2.7  .  I have not done any overlaying b/c of this but my app on the device is slow. When I click a list item or Back button, it takes like 2 [More]
I need different fonts in one ITEM on a report. Can I put scape characters in a table column? Thanks.Report fields can only have one font and you they don't recognise special characters (unless you are outputting to HTML and set the "contains html&qu [More]
I am setting the Sort Order on a column which is based on a lookup table. When generate the the module, designer does not generate the code for the Sort Order that I set on the lookup table column. Is there a work around for this problem or is there [More]
Is there a way to change an ICC profile to make it more easily found in the list of icc profiles in photoshop.  I have a micorsoft 7 systemAgreed! Some of the manufacturers out there really make it tough to figure out a profile - with Ilford paper pr [More]
pls,can anyone tell me? how to create progress bar? thanks, screen410099it is well documented how to create progressbars on page 173 in Solutions.pdf also you can find sample code in InDesign SDK\sources\sdksamples Regards BartekRead other 2 answers [More]
When annotating a pdf document using preview, is there a way to search your annotations??  Thanks!!Thanks!  I appreciate your response.  I should have followed with a question about other options, but now that I've checked the Preview Help I see that [More]
Noticed an issue with touch interface when compiling using AIR SDK 3.8.0.1430 (latest SDK and testing using latest AIR Windows player-both 3.8.0.1430). Testing on Windows 8 Pro desktop with full multitouch screen. Touch fails to work using  SWF compi [More]