Function to allow only printable ASCII in data

Hi,
In my CSV upload utility, I've implemented various error checking functions (not a number, not a valid date, not null... etc.), but today I found some strange characters in customer's DB, which was uploaded previously by someone else using sqlldr. Those characters look like small squares from sql developer, so I'm guessing the users had cut-and-paste characters from a different language or special symbols (like the trademark character cut out from Word).
I'd like to make a function or procedure to check for such characters. Basically I want to only include printable characters found only on an English keyboard. Are there any SQL or PL/SQL functions to check for this? Would the regexp_like function be helpful? If so then I'll probably need a reference table that translate between a character and it's chr(x) number for checking.
Many thanks.

Have you tried writing a loop to identify the squares in your character set?
declare
begin
for i in 0...255 loop
dbms_output.put_line(i);
dbms_output.put_line(chr(i));
end loop;
/

Similar Messages

  • In Outbound Delivery, PGI to be allowed only to the Current Date(System dt)

    Dear Friends,
    Kindly provide me the options to check that the PGI to be done only for the Current date ( System Date ) in Outbound Delivery.
    Thanks & Regards
    T.Arulvanan

    Hi,
    Please ellorate your question in more detail.
    Normally the system does the PGI date is the current date.You can check in Actual Goods Movement Date.
    Thanks & Regards,
    Hemant Patil

  • Hi, I have macbook Pro, running Leopard OS X. I partitioned my hard drive a while ago to install windows and only allowed myself 10 Gig of data. Anyway, i deleted windows and want another OSX on there instead. How do i make this partition bigger please??

    Hi, I have macbook Pro, running Leopard OS X. I partitioned my hard drive a while ago to install windows and only allowed myself 10 Gig of data. I deleted windows after i realised i wasnt enjoying using it at all and wasted my hard drive. I now decided that i want another OSX on there instead yet i have only allowed myself 10 gb on the partition. I have ben thru some programms but am struggling on making this partition bigger.
    I only want it at 20gb but cant seem to make the partition bigger, only smaller or split it into further partition.
    Is there a way to do this, i have all installation discs from original OSX so think this could help.
    Any help please would be fantastic.
    Thanks Chris

    Hi, dragging the partition will only make smaller, not larger. In disk utility you can only split or make smaller the partitions. Yes i booted from installation disks also but still no help.
    And Brody, I am willing to erase the disc completely, infact jus started doing a backup in order to do so but that failed also. And the information you gave on partition a hard drive, Although very simple and i already know how to do this, but it wont let me make the partition bigger, and i dont want to make a new partition, just enlarge the one i already have, which i dont see possible from disk utility.
    Getting really frustrated now, even backing up is saying no to me. **** external being a douche.
    I dont mind erasing the hard drive but surely this must be doable without deleting the secondary partition back t a single volume, and re partitioning into 2 volumes again.
    Thanks again

  • IOS obviously allows only 10 Apps to be Chosen in The "Open in" function. How can I control which Apps ( if more than 10 are installed) can be selected?

    iOS obviously allows only 10 Apps to be Chosen in The "Open in" function. How can I control which Apps ( if more than 10 are installed) can be selected?

    I think that is influenced by the order in which the apps are installed on the iPad (I believe that it's the most recent 10 ?) - but as I haven't got more than 10 apps that support any document/file type I can't check.
    If you want to able to edit the list, then you could try leaving feedback for Apple : http://www.apple.com/feedback/ipad.html

  • Edit Return Addresses - Invalid hostname. Only US-ASCII characters are allowed.

    On our two C series appliances the C350 and the C660 we can log in to the GUI and go to System Administration \ Return Addresses and change the
    Return Addresses for System-Generated Email to something more meaningful and practical then reports@hostname.  For example we like to use a proper suffix instead of @hostname we use @ourAwesomeCompany.com. Anyway on the M series the M650 we can't change the suffix East of the @ sign.  We get this error:
    Invalid hostname. Only US-ASCII characters are allowed.
    Did any of you, or can any of you change the Return Addresses on your M series?  You don't have to go as far as commiting the changes if you are willing to try this for me, just type something in and hit Submit that should be enough to generate the error.

    Hello,
    We have two M1060.
    When we tested the version 7.7.0-206 or earlier, we found the same problem as you by GUI.
    Recently, we're migrating to 7.9.0-107 and that is right now.
    So, you can migrate without fear

  • Lock objects to allow 1 user to insert data at a time

    Is it possible to Use lock objects to allow only 1 user to insert data into a  database table at a time.
    I am creating Assets using "BAPI_FIXEDASSET_CREATE1".
    To create "n" assets similar to the asset I use a DO loop in my program and call the BAPI. (Please refer number of fixed assets field in AS01).
    I need to avoid other users from manually creating assets using AS01 while the BAPI is running so that the range of assets created is consistent ( without gaps )
    Thanks and Regards,
    Ashwin

    <b>Lock objects</b> are use in SAP to avoid the inconsistancy at the time of data is being insert/change into database.
    SAP Provide three type of Lock objects.
    - Read Lock(Shared Locked)
    protects read access to an object. The read lock allows other transactions read access but not write access to
    the locked area of the table
    - Write Lock(exclusive lock)
    protects write access to an object. The write lock allows other transactions neither read nor write access to
    the locked area of the table.
    - Enhanced write lock (exclusive lock without cumulating)
    works like a write lock except that the enhanced write lock also protects from further accesses from the
    same transaction.
    You can create a lock on a object of SAP thorugh transaction SE11 and enter any meaningful name start with EZ Example EZTEST_LOCK.
    Use: you can see in almost all transaction when you are open an object in Change mode SAP could not allow to any other user to open the same object in change mode.
    Example: in HR when we are enter a personal number in master data maintainance screen SAP can't allow to any other user to use same personal number for changes.
    Technicaly:
    When you create a lock object System automatically creat two function module.
    1. ENQUEUE_<Lockobject name>. to insert the object in a queue.
    2. DEQUEUE_<Lockobject name>. To remove the object is being queued through above FM.
    regards,
    srinivas
    <b>*reward for useful answers*</b>

  • Analytic Functions - Need resultset only in one select

    Hello Experts,
    Problem Definition: Using Analytic Function, get Total sales for the Product P1 and Customer C1 [Total sales for the customer itself] in one line. I want to restrict the ResultSet of the query to Product P1, please look at the data below, queries and problems..
    Data
    Customer Product Qtr Sales
    C1 P1 19991 100.00
    C1 P1 19992 125.00
    C1 P1 19993 175.00
    C1 P1 19994 300.00
    C1 P2 19991 100.00
    C1 P2 19992 125.00
    C1 P2 19993 175.00
    C1 P2 19994 300.00
    C2 P1 19991 100.00
    C2 P1 19992 125.00
    C2 P1 19993 175.00
    C2 P1 19994 300.00
    Problem, I want to display....
    Customer Product ProdSales CustSales
    C1 P1 700 1400
    But Without using outer query, i.e. please look below for the query that returns this reult with two select, I want this result in one query only..
    Select * From ----*** want to avoid this... ***----
    (Select Customer,Product,
    Sum(Sales) ProdSales,
    Sum(Sum(Sales)) Over(Partition By Customer) CustSales
    From t1
    Where customer='C1')
    Where
    Product='P1' ;
    Also, I want to avoid Hard coding of P1 in the select clause....
    I mean, I can do it in one shot/select, but look at the query below, it uses P1 in the select clause, which is No No!! P1 is allowed only in Where or Having ..
    Select Customer,Decode(Product, 'P1','P1','P1') Product,
    Decode(Product,'P1',Sales,0) ProdSales,
    Sum(Sum(Sales)) Over (Partition By Customer ) CustSales
    From t1
    Where customer='C1' ;
    This will get me what I want, but as I said earlier, I want to avoid using P1 in the
    Select clause..
    Goal is to Avoid using
    1-> Two Select/Outer Query/In Line Views
    2-> Product 'P1' in the Select clause...No hard coded product name in the select clause and group by clause..
    Thanks
    -Dhaval

    Select * From ----*** want to avoid this... ***----
    (Select Customer,Product,
    Sum(Sales) ProdSales,
    Sum(Sum(Sales)) Over(Partition By Customer)
    CustSales
    From t1
    Where customer='C1')
    Where
    Product='P1' ;
    Goal is to Avoid using
    1-> Two Select/Outer Query/In Line ViewsWhy?

  • Aggregation of analytic functions not allowed

    Hi all, I have a calculated field called Calculation1 with the following calculation:
    AVG(Resolution_time) KEEP(DENSE_RANK FIRST ORDER BY RANK ) OVER(PARTITION BY "User's Groups COMPL".Group Name,"Tickets Report #7 COMPL".Resource Name )
    The result of this calculation is correct, but is repeated for all the rows I have in the dataset.
    Group Name      Resourse name    Calculation1
    SH Group            Mr. A            10
    SH Group            Mr. A            10
    SH Group            Mr. A            10
    SH Group            Mr. A            10
    SH Group            Mr. A            10
    5112 rowsI tried to create another calculation in order to have only ONE value for the couple "Group Name, Resource Name) as AVG(Calculation1) but I have the error: Aggregation of analytic functions not allowed
    I saw also inside the "Edit worksheet" panel that the Calculation1 *is not represented* with the "Sigma" symbol I(as for example a simple AVG(field_1)) and inside the SQL code I don't have GROUP BY Group Name, Resource Name......
    I'd like to see ONLY one row as:
    Group Name      Resourse name    Calculation1
    SH Group            Mr. A            10....that it means I grouped by Group Name, Resource Name
    Anyone knows how can I achieve this result or any workarounds ??
    Thanks in advance
    Alex

    Hi Rod unfortunately I can't use the AVG(Resolution_time) because my dataset is quite strange...I explain to you better.
    Ι start from this situation:
    !http://www.freeimagehosting.net/uploads/6c7bba26bd.jpg!
    There are 3 calculated fields:
    RANK is the first calculated field:
    ROW_NUMBER() OVER(PARTITION BY "User's Groups COMPL".Group Name,"Tickets Report Assigned To & Created By COMPL".Resource Name,"Tickets Report Assigned To & Created By COMPL".Incident Id  ORDER BY  "Tickets Report Assigned To & Created By COMPL".Select Flag )
    RT Calc is the 2nd calculation:
    CASE WHEN RANK = 1 THEN Resolution_time END
    and Calculation2 is the 3rd calculation:
    AVG(Resolution_time) KEEP(DENSE_RANK FIRST ORDER BY  RANK ) OVER(PARTITION BY "User's Groups COMPL".Group Name,"Tickets Report Assigned To & Created By COMPL".Resource Name )
    As you can see, from the initial dataset, I have duplicated incident id and a simple AVG(Resolution Time) counts also all the duplication.
    I used the rank (based on the field "flag) to take, for each ticket, ONLY a "resolution time" value (in my case I need the resolution time when the rank =1)
    So, with the Calculation2 I calculated for each couple Group Name, Resource Name the right AVG(Resolution time), but how yuo can see....this result is duplicated for each incident_id....
    What I need instead is to see *once* for each couple 'Group Name, Resource Name' the AVG(Resolution time).
    In other words I need to calculate the AVG(Resolution time) considering only the values written inside the RT Calc fields (where they are NOT NULL, and so, the total of the tickets it's not 14, but 9).
    I tried to aggregate again using AVG(Calculation2)...but I had the error "Aggregation of analytic functions not allowed"...
    Do you know a way to fix this problem ?
    Thanks
    Alex

  • Coding in the Trasformation  to allow only few currency types.

    HI
    Can you please let me know how i can write a program which allows only few currency's to be accepted and if other then these currency exists that particular record to be deleted before loading into the PSA
    I wrote a code llike this but this is only valid for ZAR
    *delete SOURCE_PACKAGE where CURRENCY ne 'ZAR'.
    for example if i want to allow ZAR, USD, EUR only
    hwo can i code this in the Start Rotine in the TRansformations.
    please let me know
    regards
    Krishna Mohan.

    Hi Krishna,
    You can try this code :
        data: s_cur   type c length 3.
        data : i_rng_cur like range of s_cur.
        data : rng_cur  like line of i_rng_cur.
        rng_cur-sign = 'I'.
        rng_cur-option ='EQ'.
        rng_cur-low = 'ZAR '.
        append rng_cur  to i_rng_cur.
        rng_cur-low = 'USD '.
        append rng_cur  to i_rng_cur.
        rng_cur-low =  'EUR '.
        append rng_cur  to i_rng_cur.
       delete source_package where CURRENCY  not in i_rng_cur .
      This code will delete all currency other than  ZAR ,EUR ,USD.You can append more values if you want .
    Regards,
    Jaya Tiwari

  • Transfer on last day allowed only in closed fiscal year

    Hi Guru,
    Client kept asset transfer date as 31/10/2010 first, uploaded some asset on this date, due to some reason asset uploading was not completed for all the asset. so all the asset value which was uploaded on 31/10/2010 was done as zero.
    Client took decision to upload all the asset on last day of FY 10-11 i.e 31-03-2011. transfer date was changed as 31-03.2011 and moved up to quality, unfortunatly rquest was not moved to PRD and while uploading to PRD again 25 asset got uploade  by transfer date as 31/10/2010, when realized transport req of change transfer date is moved to PRD and abt 50000 asset of total 70000 asset got uploaded.F.Y 2010 was closed while uploading this assets
    Year 2010 was again open for posting of cj88 transaction.
    When we are uploading balance  assets in the system  getting error message Transfer on last day allowed only in closed fiscal year
    When tried to close FY 2010, system is giving message ' Depreciation not posted completly' for 25 assets.
    i tried to do value as zero for these asset through as92 but system agiain giving message Transfer on last day allowed only in closed fiscal year
    so situation is we are not able to close FY 2010 and thus assets are not getting uploaded. if we run depreciation for said 25 assets for year 2010 it is not proper because actual  transfer date is 31.03.2011
    Please Help
    Regards,
    Shekhar

    hi,
    go to customizing and under asset data transfer - parameters for data transfer - date specifications - specify transfer date/last closed FY--- you need to place the last day of the period where you have last run depreciation for the legacy system and make sure that I am assuming at this stage will be the previous period or this period.
    rgds,
    jay

  • Error In MIRO GL  account allows only output tax

    Hello All,
    We are facing an error in MIRO that GL account xxxxx allows only out put tax. The scinario & settings are as  below.
    FB60
    There is no error when using the particular tax code sytem posts the document
    MIRO
    Same vendor & tax code used as in FB60
    The systemshows an error that GL  ***** allows only output tax.
    TAX CODE settings in FTXP
    The GL showing error is in tax code
    GL settings
    In GL master data in control tab , the tax category is defined as out put tax
    QUERY
    Why in FB60 it allows the GL & not in MIRO ( Both are vendor invoice and suppose to work in similar manner)
    please note in both the cases the entries are same
    Vendor Cr
    Expense / Stock Dr
    VAT GL **** Cr
    VAT GL-2 Dr
    VAT GL**** is not picking @ MIRO & Picks @ FB60 with out any error
    Any Idea !!!
    Thanks & Regards
    Arun R

    Hi,
    The problem is resolved .
    The error was due to the fact that the VAT was an aquisiton tax for europe.
    The details are in note  373587
    Thanks for the support
    Regards
    Arun

  • Allow a simple form with "data" to be saved by the user.

    Back in version -x, it used to be so simple.  You created a form that could be read in a web browser.  Users could could fill out the form and save the form to their computers with their data.  Since that first version that allowed that, Acrobat has not progressed in logical fashion.  In a later version, you couldn't save the data.  Then in another version, you could again save the data.  Now you have some nice interactive features. I appreciate the new developments and see where they could be a godsend.  However, the simple thing that I used to be able to do in version -x, and the thing I most want to do,  I can no longer do and it is frustrating.
    Here's the situation:  we have an announcement on the web for Vacation Bible School.  We want to have a pdf with a form that people can fill out online and save to their disk (as their copy of the registration form) and then print out one copy of the form so that they can send it along with their check for the registration fee.  Why should that be so difficult?
    If it weren't for the fact that people have to send in checks, one of the fancy new options would work.  But it is not applicable in this situation.
    Here are my current options:
    I can "distribute" an emailable form (which I don't want to do) and then explain to the user that they should not hit the "submit" button but save the file to their disk.  (First rule of public relations - Don't confuse the public!)  It works in the last version of REader 8+ and in Reader 9.
    I can save the form without distributing it. But the user can't save it with the data!
    Please, PLEASE, PLEASE.  Allow a simple form with "data" to be saved by the user.
    Peace and blessings
    Barbara

    Thanks for a quick response.
    In Acrobat *8 or 9 Professional you can enable a form to be activated with the save feature.
    How do you do this.  When I saved the form without distributing it, and opened the form up in Acrobat Reader, the header said specifically that the data could not be saved in the form.  And when I went to save it, I got the message in a popup that said "Data in this form will not be saved. Reader can only save a blank copy of this form."  Then a second message (with a light bulb) said:  "Please print your completed form if you would like a copy for your records."
    So, if in fact I can have the form (without "distributing" it) so that the user can save the form with the data, how do I do that?  Are there commands I use, options?  Please let me know.  I will be eternally grateful.
    Also, if you edit form fields, you may remove the submit button.
    The edit form fields does not offer any access to the submit button.
    Best,
    Barbara

  • Function Module working only in debug mode

    Hi all,
    The following Function Module works only in debug mode. The purpose of this FM is to create a notification and to put it in progress status. If I put a breakpoint before "CALL FUNCTION 'BAPI_ALM_NOTIF_PUTINPROGRESS'" it works. If I execute this FM without putting a breakpoint at that place it creates the notification but doesnt put it in progress status.
    In other words, the last BAPI call doesnot work if I dont put a breakpoint before.
    Can somebody help me to find out where is the problem?
    Thanks,
    Younes
    FUNCTION ZFM_CREATE_NOTIF_IN_PROCESS.
    ""Local interface:
    *"  IMPORTING
    *"     VALUE(NOTIFTYP) TYPE  CHAR2
    *"     VALUE(NOTIFHEADER) TYPE  BAPI2080_NOTHDRI
    *"  EXPORTING
    *"     VALUE(NOTIFNUMBER) TYPE  CHAR12
    *"     VALUE(NOTIFCURSTATUS) TYPE  CHAR40
    DATA: gs_bapi2080_nothdre TYPE bapi2080_nothdre,
          gt_return TYPE TABLE OF bapiret2.
    The notification is created with a temporary number
    CALL FUNCTION 'BAPI_ALM_NOTIF_CREATE'
      EXPORTING
        notif_type         = NOTIFTYP
        notifheader        = NOTIFHEADER
      IMPORTING
        notifheader_export = gs_bapi2080_nothdre
      TABLES
        return             = gt_return.
    READ TABLE gt_return TRANSPORTING NO FIELDS WITH KEY type = 'E'.
    CHECK sy-subrc IS NOT INITIAL.
    *The notication will be saved with a number which isnt temporary
    CALL FUNCTION 'BAPI_ALM_NOTIF_SAVE'
      EXPORTING
        number      = gs_bapi2080_nothdre-notif_no
      IMPORTING
        notifheader = gs_bapi2080_nothdre
      TABLES
        return      = gt_return.
    READ TABLE gt_return TRANSPORTING NO FIELDS WITH KEY type = 'E'.
    CHECK sy-subrc IS NOT INITIAL.
    CALL FUNCTION 'BAPI_TRANSACTION_COMMIT'.
    The Notif is already created, it will be put in progress status
    NOTIFNUMBER = gs_bapi2080_nothdre-notif_no.
       CALL FUNCTION 'BAPI_ALM_NOTIF_PUTINPROGRESS'
            EXPORTING
              NUMBER             = NOTIFNUMBER
              LANGU              = SY-LANGU
           IMPORTING
             SYSTEMSTATUS       = NOTIFCURSTATUS
           TABLES
             RETURN             = gt_return.

    Hi Emmanuel,
    Now I get your problem: you want to wait to have the commit finished! The call to BAPI_TRANSACTION_COMMIT has an optional parameter 'WAIT' which is space by default which causes only a commit. When you set this parameter to 'X' it will do a commit work and wait.
    This should solve your problem!
    Regards,
    John.

  • Allow only one set of parameter values for all worksheets

    I would like to " Allow only one set of parameter values for all worksheets ", but prompt before executing the worksheet. This function is a great time saver, but the users on occasion would like to change at the least one of the parameters. Is this possible? What setting do I use? I've tried various combinations of the " After opening a workbook: " on the options page. " Run query automatically", " Don't run query (leave sheet empty) ", and " Ask for comformation ". I would have thought that "Ask for comformation " was the trick, but no. I'm considering putting a do nothing parameter that has the setting of " Allow different parameter values for each worksheet. " so that it will keep all the others, default this one, but prompt for a possible change.
    Any thoughts...
    Thanks,
    Jamie

    Hi Jamie
    Even though you have the same parameter for all worksheets a user can still choose what to use on a worksheet. Its just that if they click to another worksheet then that parameter will be applied.
    Which version of Discoverer are you using?
    Best wishes
    Michael

  • MIRO should be allowed only for the accepted Qty (QC accepted qty)

    Hi Friends
    I have one more requirement ,
    MIRO should be allowed only for the accepted Qty (QC accepted qty) or Subcontract MIRO should be allowed only for the quantity accepted by QC
    with QM control key in material master(QM view) we can block for payment,
    but  my query is  MIRO should not be saved (message should come qty still lying in Quality inspection stock)
    Please let me know the settings,
    Thanks & Regards
    Gajendranath

    Hii,
    Yes it is possible to restrict Invoice passing in MIRO if the Stock is in Quality stock / Blocked stock. The concept is while doing MIRO, u can validate the criteria by clicking simulation tab. U can get the things in BADI (Business ad in function) with the BADI object name as "Invoice_update".
    The working is when the material is in quality stock & If ur doing MIRO for the same material, then system will pop up the message that "material with "X" qty is in quality stock" Invoice cannot be made. System does'nt allow u to pass the Invoice unless the stock is cleared from the quality. Even for the blocked stock we can simulate these error pop message.
    with regards,
    K.Lokesh.

Maybe you are looking for