Describe in SQL script does not work as you wish

Hello

Could you please help me determine why this script does not work.
He said that the date is not set.

Thanks in advance


set p_day_sh = & data_sh
set p_rowid_sh = & rowid_sh
declare
date of p_day_sh;
p_rowid_sh varchar2 (18);
Start

If & p_day_sh is not null then
trains t update
Set t.offdate = to_date ('& p_day_sh ',' DD-MM-YYYY HH24:MI:SS')
where t.rowid = '& p_rowid_sh';
commit;
end if;
end;

Hello

In a command SET, if the string to the right of the = sign contains spaces, then it must be in quotes: in the case otherwise, only the first group of characters, white space will be affected.
For example:

define p_day_sh = &data_sh

If & data_sh has this value:

11-06-2009 06:25:09

then the DEFINE command is

define p_day_sh = 11-06-2009 06:25:09

and & p_day_sh Gets the value of the part to the workspace:

11-06-2009

Either eliminate the space, Alex has proposed, or place the chain on the right side of the sign = in double - quote:

define p_day_sh = "&data_sh"

The double quotes will not change the meaning if & data_sh contains no white space.

Tags: Database

Similar Questions

  • Help and Support does not work as you wish

    Original title: Help and Support Center

    I'm finding that doing a search using Help and Support Center search box, looking for is more responses on the microsoft site, as it has already done. This aid was dropped for Microsoftxp home version 2002 service pack 3 , or is there a problem that I don't know about my system? Any help or information would be appreciated.

    For those who have experienced this problem

    I note that all solutions have been validated, IE

    1 re - install & support.

    2. run SFC/scannow,

    3. create a new user profile by means of microsoft suggeted,

    "Are not, (I repeat, not) work to solve this problem

    The only solution I've found that works is to

    1 create a new user

    2. move ( NOT copy) all of your files and folders in My Documents,my music, my pictures, and my videos folders of your damageduser profile for the new user profile in place corresponding installs under this new profile.

    3. do not copy or move hidden files or folders that you do not have created and hidden from yourself.

    4. you must also ensure you save settings, emails and contacts (contacts already in the .pst in Outlook file) by using the appropriate method for your e-mail program to allow for the recovery of these in your new profile.

    5. you can export your Favorites RSS (and biscuits)Internet Explorer under your old profile to a file in your new profile, and then import them from your new profile, after that you run Internet Explorer from here.

    6. don't worry about the programs, they are available to all users.

    I hope this can help someone else, who had the same problem I did.

    Aussie

  • Tiara startup script does not work when running file associated with

    Hello

    I have a startup script that works correctly with tiara itself, however when I open a file associated with tiara (tdms files) the startup script does not work.  Is it possible to ensure that the script runs without worrying?  Thanks for the help!

    Bala

    Hi Bala,

    Depending on your use case, I suggest you call the next VI, which comes with LabVIEW, after your purchase VI is the creation of the data file.  Just pass the data file path in the upper part of entry and your path to the VBScript file in less than entry.

    "C:\Program Files (x 86) \National Instruments\LabVIEW 2013\vi.lib\ExportToExcel\DIAdem report Assistant Start CSC.vi '.

    Brad Turpin

    Tiara Product Support Engineer

    National Instruments

  • Point culminating script does not work correctly

    I try to get the yellow filled rectangle to become visible behind the digital field when the numeric field is greater than "1". Can anyone help to see why my script does not work?

    https://Acrobat.com/#d=MJObRvA * l9tbFmrlHcMHUA

    Thank you

    -Don

    Hi Don,

    Your code does not work because because it is not actually executed. It's because of put you the code on the text box itself output event and this would require the user to move to that field and then leave the field and then run the code.

    I would recommend you change you form to add this code at the end of the code that runs your "addAttachment" button and then the form works as I expect.

    If (NumberOfAttachments.rawValue > 1) {}

    RectangleYellow.presence = "visible";

    }

    Hope this helps

    Malcolm

  • Why the highlighting of text in a PDF document does not work after you save the file

    Why the highlighting of text in a PDF document does not work after you save the file

    What application you use to highlight?

  • Microsoft Pinball Arcade, everything works except the right flipper does not work when you run the game. __Keyboard is very good

    Microsoft Pinball Arcade, everything works except the right flipper does not work when you run the game.
    Keyboard is fine.  Is this a compatibility issue?

    ---------------

  • AutoPlay feature does not work when you insert a CD-ROM into the CD drive

    Original title: computer disc drive

    Download or CD extract of music reading, record music, download CD etc... Before my hard drive had to be replaced, when a disc is inserted into my computer, a window appears, asking what you want to do... Burn music, Rip, copy in folder etc... now when I insert a disk, the window no longer appears, which gives you options and you get to this site... How can I get that back?

    Hey Big-Mack,

    Try the steps of troubleshooting mentioned in the following article and check the result.
    See the enforcement function automatic or AutoPlay feature does not work when you insert a CD-ROM into the CD drive

    If the problem persists, run the Autoplay Repair Wizard and check the result.
    See Autoplay Repair Wizard

    Play functionality; New in Windows Media Player 12 makes it easy to listen to the music, video and photos from your computer to other computers, TVs or stereo on your home network.
    For more information, see play in

    Visit our Microsoft answers feedback Forum and let us know what you think.

  • print DigitalPersona finger scanning does not work after you install the recommended updates

    My impression of digitalpersona finger scanning does not work after you install the updates recommended on my dell Vista

    Hello

    1. do you have an error message?
    2. are you referring to the print scan hardware or software scan print that was supplied with the device?

    Method 1:
    I suggest you to update the software DigitalPersona from the link below https://www.digitalpersona.com/support/downloads/

  • my touch screen does not work after you download windows 8.je have a B305 lenovo all in one PC ideas?

    my touch screen does not work after you download windows 8.je have a B305 lenovo all in one PC ideas?

    I downloaded the former driver of windows 7 touchscreen and it worked

  • Question 1: The button "Buy now" does not work when you select a plan. Question 2: Can not select "Monthly Plan" for a "unique App."

    Question 1: The button "Buy now" does not work when you select a plan.

    How to reproduce the problem:

    1. go in terms of pricing and membership creative cloud | Adobe Creative Cloud

    2. choose a plan, then click on 'buy now '.

    3. you go to a blank page instead of the next steps in the payment.

    Question 2: Can not select "Monthly Plan" for a "unique App."

    How to reproduce the problem:

    1. go into "https://creative.adobe.com/plans".

    2. under "Unique App", select a product and then try to select the "monthly Plan" in the second menu drop-down.

    3. for some reason, it isn't get selected and the price is replaced with the ellipsis (...). I expect the monthly price to appear.

    Please notify.

    Thank you.

    Contact adobe during the time pst support by clicking here and, when available, click on "still need help," http://helpx.adobe.com/x-productkb/global/service-ccm.html

  • Hello my laptop its in Portuguese and I need my cc of photoshop in English, I changed in English, but it does not work, could you help me with this? Thank you.

    Hello my laptop its in Portuguese and I need my cc of photoshop in English, I changed in English, but it does not work, could you help me with this? Thank you.

    Uninstall your Portuguese ps.

    change the installation language in your cc in English desktop app.

    then reinstall your ps.

  • How your SEO does not work if you move your Web site to another host?

    How your SEO does not work if you move your Web site to another host?

    Thank you

    Michael

    Hi Michael

    Move single accommodation, should not influence seo. Change the site host requires a change in the location of the file, so no impact. However, I found a video that will understand this

    Let me know if you have any question.

  • ACCEPT in SQL script does not

    G ' Day

    Why the use of the key word 'accept' does not work?

    I want a user to be prompted to commit or rollback, but it does not work in the following 'experience '.


    set echo on
    Set termout on
    Set of feedback on
    Update emp set sal = sal * 2 where ename = 'SCOTT ';
    accept char prompt action ' rollback or commit > '
    & action

    This is what happens when I run the script:

    SQL > @temp02.sql
    SQL > set echo on
    SQL > set termout on
    SQL > set comments on
    SQL > update emp set sal = sal * 2 where ename = 'SCOTT ';

    1 line update.

    SQL > accept char prompt action ' rollback or commit > '
    Rollback or commit > restoration
    SQL > & action
    SP2-0042: unknown '& action' - command remains ignored line.


    Any suggestion is appreciated.

    Tony

    Hi, Tony,.

    Welcome to the forum!

    SQL * more looks at the first word of a statement before solving the substitution variables. (I don't know why, it solves them regardless of which is the command.) In any case, the first word in an SQL command * more interpreter must be specified.

    "BEGIN" which begins an anonymous block counts as the first word, so you can take the suggestion of Andy much further by saying simply:

    BEGIN
        &action;
    END;
    /
    

    @ also account as the first word, then you might also have a script called commit.sql line

    COMMIT;
    

    and rollback.sql,

    ROLLBACK;
    

    and then tell

    @&action
    
  • RMAN script does not work as a cron job, but works when explicitly executed

    Oracle 10 g 2 10.2.0.1, Oracle Enterprise Linux 4 U7.

    I've added a task to crontab of the oracle user who looks like the following:
    #ORACLE_HOME,ORACLE_SID and PATH are set in the user's profie
    TAG=`date|awk '{print $1"_"$2"_"$3}'| tr [:lower:] [:upper:]`
    
    echo "backup started on`date` "> /home/oracle/rman.log
    
    rman target / LOG='/home/oracle/rman_run.log' << EOF
    
    run{
    
    sql 'aler system switch logfile';
    backup full database tag='$TAG' include current controlfile;
    delete noprompt obsolete;
    
    }
    exit;
    EOF
    
    echo "rman finished, returned $? " >> /home/oracle/rman.log
    echo "Backup ended on `date` " >> /home/oracle/rman.log
    the tracks work as expected but the rman command never works the inside of cron, it always returns code 1, but if I call the script itself from the command line
    It works smoothly and the backup is performed.

    what I am doing wrong?

    what I am doing wrong?

    no no no ORACLE_HOME and ORACLE_SID is defined in script
    The script does not source in the script of environmental requirements

    env | Tri o /tmp/capture.env

    above indicates how deficient the script environment cron is really

  • Global Script Protection activation does not work when you add '&amp; '.

    Hi all

    To prevent crosssite scripting attacks I ticked the checkbox 'Enable Global Script Protection' in the admin CF. But it doesn't work, I mean not able to prevent the attacks by scripts.

    I followed steps

    1] I run the below URL.

    https://xyz.ABC.com/index.cfm?cardholder_number= & < script > alert (1) < /script >

    [2] fornt ultimately I got a javascript alert message as injected into the URL.

    But this alert message should not be that I activated the script protection in CF Admin. law?

    Now, I have removed '&' (https://xyz.abc.com/index.cfm?cardholder_number= < script > alert (1) < /script >) since the above URL then I wasn't getting the javascript alert message. Does that mean that protection of script will not work if we add '&' to the URL?

    I searched the neo - security.xml and its looks like below.

    < var name = "CrossSiteScriptPatterns" > < struct type = 'coldfusion.server.ConfigMap' > < var name = '& lt; \s*(object|embed|script|applet|meta)' > < String > & lt; InvalidTag < / string > < / var > < /st ruct > < / var >

    Can someone help me solve this problem.

    Abdul L Koyappayil says:

    But even when a remnant of doubt why alert message is coming when there is '&' in the URL?

    This happens with "&" because it is a symbol special "Javascript" whose purpose is to delimit - i.e. separated - value of the URL query string key-value pairs. For example, in the URL www.myDomain.com/index.cfm?a=1&b=2, the '&' defines the query string in the key-value pairs 2

    a = 1

    b = 2

    Consider the case where the URL is www.myDomain.com/index.cfm?cardholder_number=& then . The & will delimit the query string in

    cardholder_number =

    The presence of '&' implies there are 2 variables. However, there is that a single sign "=", which means there is only a pair of key / value. In addition, cardholder_number is a name for a URL variable, while is not. The browser then sends the query string next to your application

    cardholder_number = EMPTY_STRING &

    However, Coldfusion's scriptprotect feature will intervene and this to neutralize

    cardholder_number = alert (1) EMPTY_STRING &

    that is harmless. These will come into Coldfusion variables URLS

    cardholder_number = EMPTY_STRING

    EMPTY_STRING = EMPTY_STRING

    The special nature of '&' as delimiter is what drives the browser to run the script. Indeed, by default, browsers will run any Javascript you place in the query string. Running, for example

    http://www.myDomain.com/index.cfm?

    But why tell I if they ask me why javascript alert then.

    As you have seen, the

    This isn't the case here.

Maybe you are looking for

  • Impossible to install El Capitan of App Store more

    Dear Sir I have a MacBook Pro, which was launched before 2010. So I can only install El Capitan, which is no longer available on the App Store. How can I get an installer of El Capitan? In advance, best regards Carlos

  • Sort by song stopped working correctly w/ios10 - how can it be fixed? It now sorts Alpha by artist

    The update on my iPhone ios10 - caused iTunes SONG sorting malfunction. Now, he's going in alphabetical order by ARTIST, then the songs from this artist. Instead of Alpha under the name of the song. Is determined and resolved?

  • cancelled downloads keep coming back after the restart

    Hello guys. After the Update beta, beta 9 if I remember well (on the section of the said browser ver 32) downloads are badly behave. the first problem I have encountered is when I downloaded a (approximately 40 KB) zip file, the zip is downloaded on

  • A sequence controlled by an input button

    Hi guys. I want to create a sequence that is commanded by an entry for example a button 'NEXT' button which will begin a set of instructions assigned to step 2 of a sequential structure. Something as seen in a software installation. Can someone point

  • All security updates fail with the error A 80071, 91 code

    Hello! System information: Windows 7 Ultimate 64-bit, i7-720QM, 6 GB RAM, 256 GB SSD, ATI 4670 [Dell Studio XPS 1645] Background: UAC was arrested. Turn on UAC stop my gadgets to work [another thread on these forums...]. A week ago, I got speech reco