SQL*Plus: list of characters that need to be escaped

Hi all,
We have a requirement where we need to add comments to tables and table columns and this is done using SQL*Plus. I understand that there are some special characters that are interpreted by SQL*Plus such as ampersand (&). I would like to know the list of such characters so that we can escape them before passing it on to CREATE COMMENT ON statement. So far we have identified the following special characters:
The following characters need to be escaped no matter where they are present in the comment
single quote "'" (hex 27)
define "&" (hex 26)
sqlterminator ";" (hex 3b)
The following characters need to be escaped when they are the only character on a line
forward slash "/" (hex 2f)
blockterminator "." (hex 2e)
sqlprefix "#" (hex 23)
The following characters need to escaped if they are followed by a newline
line continuation "-" (hex 2d)
We would like to know if there are other special characters and appreciate if someone can provide the list.
Thanks
Edited by: user779842 on Aug 20, 2009 3:37 AM
Edited by: user779842 on Aug 20, 2009 3:55 AM

I think the only two characters you need to worry about in your comment strings are: ' and & (apostrophe/single quote and ampersand). The latter you can get around by doing:
set define offbefore running your statements, but the apostrophe you'll have to double up to allow oracle to recognise that it's not the end of the string. Eg:
I'm a stringwould become
'I''m a string'  -- NB. this is two single quotes, not 1 double quote!or, if you're on 10g or above, you can use the quote operator (q):
select q'#I'm a string#' from dual;See the documentation for what characters can be used as the quote delimiters: http://download.oracle.com/docs/cd/B19306_01/appdev.102/b14251/adfns_sqltypes.htm#sthref377

Similar Messages

  • How to update a large (over 4 million item) List(Of Byte) quickly by altering indexes contained in a Dictionary(Of Integer, Byte) where the Dictionaries keys are the indexes in the List(Of Byte) that need to be changed to the values for those indexes?

       I'm having some difficulty with transferring images from a UDP Client to a UDP Server. The issue is receiving the bytes necessary to update an original image sent from the Client to the Server and updating the Servers List(Of Byte) with the
    new bytes replacing bytes in that list. This is a simplex connection where the Sever receives and the Client sends to utilize the least amount of bandwidth for a "Remote Desktop" style application where the Server side needs image updates of whatever
    occurs on the Client desktop.
       So far I can tranfer images with no issue. The images can be be any image type (.Bmp, .Gif, .JPeg, .Png, etc). I was working with sending .JPeg's as they appear to be the smallest size image when a Bitmap is saved to a memory stream as type
    .JPeg. And then I am using GZip to compress that byte array again so it is much smaller. However on a loopback on my NIC the speed for sending a full size screen capture is not very fast as the Server updates fairly slowly unless the Clients screen capture
    Bitmap is reduced in size to about 1/3'd of the original size. Then about 12000 bytes or less are sent for each update.
       Due to .JPeg compression I suppose there is no way to get the difference in bytes between two .JPegs and only send those when something occurs on the desktop that alters the desktop screen capture image. Therefore I went to using .Bmp's as each
    .Bmp contains the same number of bytes in its array regardless of the image alterations on the desktop. So I suppose the difference in bytes from a second screen capture and an inital screen capture are what is different in the second image from the initial
    image.
       What I have done so far is save an initial Bitmap of a screen capture using a memory stream and saving as type .Bmp which takes less than 93 milliseconds for 4196406 bytes. Compressing that takes less than 118 milliseconds to 197325 bytes for
    the current windows on the desktop. When that is done PictureBox1 is updated from nothing to the captured image as the PictureBox's background image with image layout zoom and the PictureBox sized at 1/2 my screens width and 1/2 my screens height.
       Then I save a new Bitmap the same way which now contains different image information as the PictureBox is now displaying an image so its back color is no longer displayed (solid color Aqua) and the cursor has moved to a different location. The
    second Bitmap is also 4196406 in bytes and compressed it was 315473 bytes in size.
       I also just found code from this link Converting a Bitmap to a Byte Array (and Byte Array to Bitmap) which gets a byte array
    directly from a Bitmap and the size of that is 3148800 for whatever is full screen captured on my laptop. So I should be able to work with smaller byte arrays at some point.
       The issue I'm having is that once the Client sends an image of the desktop to the Server I only want to update the server with any differences occuring on the Clients desktop. So what I have done is compare the first screen captures bytes (stored
    in a List(Of Byte)) to the second screen captures bytes (stored in a List(Of Byte)) by using a For/Next for 0 to 4196405 where if a byte in the first screen captures List is not equal to a byte in the second screen captures List I add the index and byte of
    the second screen captures list to a Dictionary(Of Integer, Byte). The Dictionary then only contains the indexes and bytes that are different between the first screen capture and second screen capture. This takes about 125 milliseconds which I think is pretty
    fast for 4196406 byte comparison using a For/Next and adding all the different bytes and indexes for each byte to a Dictionary.
        The difference in Bytes between the inital screen capture and the second screen capture is 242587 as an example which changes of course. For that amount of bytes the Dictionary contains 242587 integers as indexes and 242587 bytes as different
    bytes totaling 485174 bytes for both arrays (keys, values).  Compressed the indexes go from 242587 to 43489 bytes and the values go from 242587 to 34982 bytes. Which means I will have to send 78, 481 bytes from the Client to the Server to update the display
    on the server. Quite smaller than the original 4196406 bytes of the second Bitmap saved to type .Bmp or the compressed size of that array which was 315473 bytes. Plus a few bytes I add as overhead so the server knows when an image array ends and how many packets
    were sent for the array so it can discard complete arrays if necessary since UDP is lossfull although probably not so much in current networks like it may originally have been when the internet started.
        In reality the data from the Client to the Server will mostly be the cursor as it moves and updating the Server image with only a few hundred bytes I would imagine at a time. Or when the cursor selects a Button for example and the Buttons
    color changes causing those differences in the original screen capture.
       But the problem is if I send the Dictionaries Indexes and Bytes to the Server then I need to update the original Bitmap List(Of Byte) on the server by removing the Bytes in the received informations Index locations array from the Servers Bitmap
    List(Of Byte) and replacing those Bytes with the Bytes in the received informations Byte array. This takes so long using a For/Next for however many indexes are in the received informations Index array to update the Bitmap List(Of Byte) on the server using
    "Bmp1Bytes.RemoveAt(Index As Integer)" followed by "Bmp1Bytes.Insert(Index As Integer, Item As Byte)" in the For/Next.
        I've tried various For/Next statements including using a new List(Of Byte) with If statements so If the the integer for the For/Next ='s the Key in a Dictionary(Of Integer, Byte) using a Counter to provide the Dictionaries Key value then
    the Dictionaries byte value will be added to the List(Of Byte) and the counter will increas by one Else the List(Of Byte) adds the original "Bmp1Bytes" byte at that index to the new List(Of Byte). This takes forever also.
       I also tried the same For/Next adding to a new Dictionary(Of Integer, Byte) but that takes forever too.
       I think I could use RemoveRange and AddRange to speed things up. But I don't know how to retrieve a contiguous range of indexes in the received indexes that need to be updated in the servers "Bmp1Bytes" List(Of Byte) from the received
    array of indexes and bytes which are in a Dictionary(Of Integer, Byte).  But I believe this would even be slower than some realistic method for replacing all Bytes in a List(Of Byte) when I have the indexes that need to be replaced and the bytes to replace
    them with.
       Even if I just used AddRange on a new List(Of Byte) to add ranges of bytes from the original "Bmp1Bytes" and the changes from the Dictionary(Of Integer, Byte) I think this would be rather slow. Although I don't know how to do that
    by getting contiguous ranges of indexes from the Dictionaries keys.
       So I was wondering if there is some method perhaps using Linq or IEnumerable which I've been unable to figure anything out which could do this.
       I do have some copy and pasted code which I don't understand how it works that I am using which I would guess could be altered for doing something like this but I can't find information that provides how the code works.  Or even if I did
    maybe I can't understand it. Like the code below which is extremely fast.
       Dim strArray() As String = Array.ConvertAll(Of Integer, String)(BmpComparisonDict.Keys.ToArray, Function(x) x.ToString())
    La vida loca

    Monkeyboy,
    That was quite a bit to read, but still a bit unclear. Could you put a specific list of goals/questions, asked in the smallest possible form?
    It seems like either you're making a program that monitors activity on your computer, or you're writing some kind of remote pc app.
    When you do get your bytes from using lockbits, keep in mind all the files header info would be lost. I think retaining the header info is worth the extra bytes.
    The other, thing: I'm not sure if you're taking 32bpp screen shots, but also keep in mind that the "whole desktop" is the final destination for blended graphics, if that makes sense. What I mean is that there is no need to capture an "alpha"
    channel for a desktop screenshot, as alpha would always be 255, this could save you 1 byte per pixel captured... Theres nothing "behind" the desktop, therefore no alpha, and every window shown above the desktop is already blended. I suggest using
    24Bpp for a full screen capture.
    Your X,Y information for the mouse could be stored as UINT16, this would save you a measly 2 bytes per location update/save.
    When you update your byte arrays, maybe you can turn the array into a stream and write to whatever index, however many bytes, that should prevent a "Shift" of bytes, and instead overwrite any bytes that "get in the way".
    ex
    Dim example As String = "This is an example."
    Dim insertString As String = "was"
    Dim insertBytes As Byte() = System.Text.Encoding.ASCII.GetBytes(insertString)
    Dim bytes As Byte() = System.Text.Encoding.ASCII.GetBytes(example)
    Dim modifiedBytes As Byte() = {}
    Using ms As New System.IO.MemoryStream(bytes)
    ms.Position = 5
    ms.Write(insertBytes, 0, 3)
    modifiedBytes = ms.ToArray
    End Using
    Dim newString As String = System.Text.Encoding.ASCII.GetString(modifiedBytes)
    'Notice how below there isn't the word "is" anymore, and that there isn't a
    'space.
    'This demonstrates that you overwrite existing data, versus shifting everything to
    'the right.
    'Returns: This wasan example.
    MsgBox(newString)
    “If you want something you've never had, you need to do something you've never done.”
    Don't forget to mark
    helpful posts and answers
    ! Answer an interesting question? Write a
    new article
    about it! My Articles
    *This post does not reflect the opinion of Microsoft, or its employees.
    Well it's too much to read. I was really tired when I wrote it. Even the below is too much to read but perhaps gets the point across of what I would like to do which I think
    Joel Engineer may have answered but I'm not sure. As I'm still too tired to understand that yet and research what he said in order to figure it out yet.
    But maybe the code below can provide the concept of the operation with the comments in it. But seeing as how I'm still tired it may be confused.
    Option Strict On
    Imports System.Windows.Forms
    Imports System.IO
    Imports System.IO.Compression
    Imports System.Drawing.Imaging
    Imports System.Runtime.InteropServices
    Public Class Form1
    Dim Bmp1Bytes As New List(Of Byte)
    Dim Bmp1BytesCompressed As New List(Of Byte)
    Dim Bmp2Bytes As New List(Of Byte)
    Dim BmpComparisonDict As New Dictionary(Of Integer, Byte)
    Dim BmpDifferenceIndexesCompressed As New List(Of Byte)
    Dim BmpDifferenceBytesCompressed As New List(Of Byte)
    Private Sub Button1_Click(sender As Object, e As EventArgs) Handles Button1.Click
    SomeSub()
    End Sub
    Private Sub SomeSub()
    ' Pretend this code is in UDP Client app. A screen capture is performed of the desktop. Takes about 90 milliseconds.
    Bmp1Bytes.Clear()
    Using BMP1 As New Bitmap(Screen.PrimaryScreen.Bounds.Width, Screen.PrimaryScreen.Bounds.Height)
    Using g1 As Graphics = Graphics.FromImage(BMP1)
    g1.CopyFromScreen(0, 0, 0, 0, BMP1.Size)
    Cursor.Draw(g1, New Rectangle(Cursor.Position.X, Cursor.Position.Y, Cursor.Size.Width, Cursor.Size.Height))
    Using MS As New MemoryStream
    BMP1.Save(MS, System.Drawing.Imaging.ImageFormat.Bmp)
    Bmp1Bytes.AddRange(MS.ToArray)
    End Using
    End Using
    End Using
    Bmp1BytesCompressed.AddRange(Compress(Bmp1Bytes.ToArray))
    ' UDP Client app sends Bmp1BytesCompressed.ToArray to UDP Server which is the entire image of the desktop that the UDP
    ' Client is on. This image takes awhile to send since compressed it is about 177000 bytes from over 4000000 bytes.
    ' I will be using different code just to get the bytes from the actual Bitmap in the future. That is not important for now.
    ' Pretend the UDP Server has received the bytes, decompressed the array received into a List(Of Byte) and is displaying
    ' the image of the UDP Clients desktop in a PictureBox.
    ' Now the image on the UDP Clients desktop changes due to the mouse cursor moving as an example. Therefore a new Bitmap
    ' is created from a screen capture. This takes about 90 milliseconds.
    Bmp2Bytes.Clear()
    Using BMP2 As New Bitmap(Screen.PrimaryScreen.Bounds.Width, Screen.PrimaryScreen.Bounds.Height)
    Using g1 As Graphics = Graphics.FromImage(BMP2)
    g1.CopyFromScreen(0, 0, 0, 0, BMP2.Size)
    Cursor.Draw(g1, New Rectangle(Cursor.Position.X, Cursor.Position.Y, Cursor.Size.Width, Cursor.Size.Height))
    Using MS As New MemoryStream
    BMP2.Save(MS, System.Drawing.Imaging.ImageFormat.Bmp)
    Bmp2Bytes.AddRange(MS.ToArray)
    End Using
    End Using
    End Using
    ' Now I have the original images bytes in Bmp1Bytes and the new images bytes in Bmp2Bytes on the UDP Client. But I don't
    ' want to send all of the bytes in Bmp2Bytes to the UDP Server. Just the indexes of and the bytes that are different in
    ' Bmp2Bytes from Bmp1Bytes.
    ' This takes less than 100 milliseconds for what I've tested so far where over 500000 bytes in Bmp2Bytes are different
    ' than the bytes in Bmp1Bytes. Usually that amount would be much less. But during testing I was displaying the image
    ' from Bmp1 bytes in a PictureBox so a large amount of data would change between the first screen shot, the PictureBox
    ' then displaying an image on the same PC and then the second screen shot.
    BmpComparisonDict.Clear()
    For i = 0 To Bmp1Bytes.Count - 1
    If Bmp1Bytes(i) <> Bmp2Bytes(i) Then
    BmpComparisonDict.Add(i, Bmp2Bytes(i))
    End If
    Next
    ' So now I have all the difference bytes and their indexes from Bmp2Bytes in the BmpComparisonDict. So I compress
    ' the indexes into on List and the Bytes into another List.
    BmpDifferenceIndexesCompressed.Clear()
    BmpDifferenceBytesCompressed.Clear()
    BmpDifferenceIndexesCompressed.AddRange(Compress(BmpComparisonDict.Keys.SelectMany(Function(d) BitConverter.GetBytes(d)).ToArray()))
    BmpDifferenceBytesCompressed.AddRange(Compress(BmpComparisonDict.Values.ToArray))
    ' Now pretend the UDP Client has sent both those arrays to the UDP Server which has added both decompressed arrays
    ' to a Dictionary(Of Integer, Byte). And the server has the original image decompressed bytes received in a List
    ' called Bmp1Bytes also.
    ' This is where I am stuck. The UDP Server has the Dictionary. That part was fast. However there is no
    ' fast method I have found for creating a new List(Of Byte) where bytes in the originally received List(Of Byte) that
    ' do not have to be altered are placed into a new List(Of Byte) except for the indexes listed in the
    ' Dictionary(Of Integer, Byte) that need to be placed into the appropriate index locations of the new List(Of Byte).
    ' The below example for doing so is exceptionally slow. Pretend UpdateDictionary has all of the decompressed indexes
    ' and bytes received by the UDP Server for the update contained within it.
    Dim UpdateDictionary As New Dictionary(Of Integer, Byte)
    Dim UpdatedBytes As New List(Of Byte)
    Dim Counter As Integer = 0
    For i = 0 To Bmp1Bytes.Count - 1
    If i = UpdateDictionary.Keys(Counter) Then ' Provides the index contained in the Keys for the Dictionary
    UpdatedBytes.Add(UpdateDictionary.Values(Counter))
    Counter += 1
    If Counter > UpdateDictionary.Count - 1 Then Counter = 0
    Else
    UpdatedBytes.Add(Bmp1Bytes(i))
    End If
    Next
    ' So what I'm trying to do is find an extremely fast method for performing something similar to what the
    ' above operation performs.
    End Sub
    Private Function Compress(BytesToCompress() As Byte) As List(Of Byte)
    Dim BytesCompressed As New List(Of Byte)
    Using compressedStream = New MemoryStream()
    Using zipStream = New GZipStream(compressedStream, CompressionMode.Compress)
    zipStream.Write(BytesToCompress, 0, BytesToCompress.Count)
    zipStream.Close()
    BytesCompressed.AddRange(compressedStream.ToArray)
    End Using
    End Using
    Return BytesCompressed
    End Function
    Private Function Decompress(BytesToDecompress() As Byte) As List(Of Byte)
    Dim BytesDecompressed As New List(Of Byte)
    Using DecompressedStream = New MemoryStream()
    Using zipStream = New GZipStream(DecompressedStream, CompressionMode.Decompress)
    zipStream.Write(BytesToDecompress, 0, BytesToDecompress.Count)
    zipStream.Close()
    BytesDecompressed.AddRange(DecompressedStream.ToArray)
    End Using
    End Using
    Return BytesDecompressed
    End Function
    End Class
    La vida loca

  • SQL*Plus and chinese characters

    Hi all,
    I have following scenario:
    1. Database 10.1.0.5 with following NLS-Parameter:
    SQL> select * from NLS_DATABASE_PARAMETERS;
    NLS_LANGUAGE AMERICAN
    NLS_NCHAR_CHARACTERSET AL16UTF16
    NLS_TERRITORY AMERICA
    NLS_CURRENCY $
    NLS_ISO_CURRENCY AMERICA
    NLS_NUMERIC_CHARACTERS .,
    NLS_CHARACTERSET WE8MSWIN1252
    NLS_CALENDAR GREGORIAN
    NLS_DATE_FORMAT DD-MON-RR
    NLS_DATE_LANGUAGE AMERICAN
    NLS_SORT BINARY
    NLS_TIME_FORMAT HH.MI.SSXFF AM
    NLS_TIMESTAMP_FORMAT DD-MON-RR HH.MI.SSXFF AM
    NLS_TIME_TZ_FORMAT HH.MI.SSXFF AM TZR
    NLS_TIMESTAMP_TZ_FORMAT DD-MON-RR HH.MI.SSXFF AM TZR
    NLS_DUAL_CURRENCY $
    NLS_COMP BINARY
    NLS_LENGTH_SEMANTICS BYTE
    NLS_NCHAR_CONV_EXCP FALSE
    NLS_RDBMS_VERSION 10.1.0.5.0
    SQL> select * from NLS_SESSION_PARAMETERS;
    NLS_LANGUAGE AMERICAN
    NLS_TERRITORY GERMANY
    NLS_CURRENCY €
    NLS_ISO_CURRENCY GERMANY
    NLS_NUMERIC_CHARACTERS ,.
    NLS_CALENDAR GREGORIAN
    NLS_DATE_FORMAT DD.MM.RR
    NLS_DATE_LANGUAGE AMERICAN
    NLS_SORT BINARY
    NLS_TIME_FORMAT HH24:MI:SSXFF
    NLS_TIMESTAMP_FORMAT DD.MM.RR HH24:MI:SSXFF
    NLS_TIME_TZ_FORMAT HH24:MI:SSXFF TZR
    NLS_TIMESTAMP_TZ_FORMAT DD.MM.RR HH24:MI:SSXFF TZR
    NLS_DUAL_CURRENCY €
    NLS_COMP BINARY
    NLS_LENGTH_SEMANTICS BYTE
    NLS_NCHAR_CONV_EXCP FALSE
    SQL> select * from V$NLS_PARAMETERS;
    NLS_LANGUAGE AMERICAN
    NLS_TERRITORY GERMANY
    NLS_CURRENCY €
    NLS_ISO_CURRENCY GERMANY
    NLS_NUMERIC_CHARACTERS ,.
    NLS_CALENDAR GREGORIAN
    NLS_DATE_FORMAT DD.MM.RR
    NLS_DATE_LANGUAGE AMERICAN
    NLS_CHARACTERSET WE8MSWIN1252
    NLS_SORT BINARY
    NLS_TIME_FORMAT HH24:MI:SSXFF
    NLS_TIMESTAMP_FORMAT DD.MM.RR HH24:MI:SSXFF
    NLS_TIME_TZ_FORMAT HH24:MI:SSXFF TZR
    NLS_TIMESTAMP_TZ_FORMAT DD.MM.RR HH24:MI:SSXFF TZR
    NLS_DUAL_CURRENCY €
    NLS_NCHAR_CHARACTERSET AL16UTF16
    NLS_COMP BINARY
    NLS_LENGTH_SEMANTICS BYTE
    NLS_NCHAR_CONV_EXCP FALSE
    2. Windows Language is german
    I should be possible to insert the chinese characters into the table from the SQL*Plus (sqlplusw.exe) and SQL*Plus should be able to show the chinese characters from that table.
    Is there any Step-By-Step Tutorial for the changes, that I should provide?
    Can anybody help me?
    Thanks

    I have a table CHINESE with one column STRING
    NVARCHAR2(250). There I will store the chinese
    character and display the content in SQL*Plus.
    Into the table I will insert with SQL*Plus with
    INSERT Statement.
    To store the character you could use e.g.
    insert unistr(<unicode value expression>) into table But Sql*Plus does not support Unicode display. Use SQL Developer instead for displaying your table data.
    You could also use select dump(column,1016) from table to verify that character data is correctly converted and stored.
    Windows Codepage is 1252.
    What do you mean under "what is your corresponding
    NLS_LANG client char set setting" ?With acp 1252, your NLS_LANG should contain .WE8MSWIN1252 - this tells Oracle your acp setting.
    Note however that windows-1252 does not define any Chinese characters.
    http://www.microsoft.com/globaldev/reference/sbcs/1252.mspx
    http://www.oracle.com/technology/tech/globalization/htdocs/nls_lang%20faq.htm
    You can read more about Unicode string literals in Oracle in chapter 7 Programming with Unicode, Globalization Support guide in 10.2. Also you probably should read about NCHAR literal replacement (available only in 10.2 and above).
    http://download.oracle.com/docs/cd/B19306_01/server.102/b14225/toc.htm
    Message was edited by:
    orafad

  • List of ports that need to be opened?

    Hi,
    A customer is using a citrix client to log on to their citrix server, which is running a B1 client. They are getting errors in relation to the connection to the licence server failing, even though they have opened the port (30000) in question to allow access.
    Do you have a list of ports/are there any other ports as standard that need to be opened for the client install to connect to the license server?
    Thanks.

    David,
    Try to browse this link:
    http://support.citrix.com
    there is a search function that you could use to find out the port or also issue regarding to citrix
    Rgds,

  • Listing all datafiles that need restore

    I get this when I try to open the database.
    ERROR at line 1:
    ORA-01113: file 10 needs media recovery
    So I go the RMAN and restore and recover datafile 10.
    Then I'm told when I try to open the database that file 12 need media recovery.
    Is there a way I can list out all the files that need recovery? So that the list would say something like this:
    file 10 needs media recovery
    file 12 needs media recovery
    file 13 needs media recovery

    Hi,
    Following query would help you:
    select* from v$recover_file;
    Regards

  • Feature to spit out a list of users that need a password reset from DB?

    Not too sure which category this would be in, so please direct me if you know
    As the title says, is there a feature or tool that exports a list of usernames that have their password expiring in, for example, the next 10-20 days? It's a common occurrence that people forget to change their password and end up being locked out. This tool would greatly make it easier on our IT dept.
    Thanks! 
    This topic first appeared in the Spiceworks Community

    Not too sure which category this would be in, so please direct me if you know
    As the title says, is there a feature or tool that exports a list of usernames that have their password expiring in, for example, the next 10-20 days? It's a common occurrence that people forget to change their password and end up being locked out. This tool would greatly make it easier on our IT dept.
    Thanks! 
    This topic first appeared in the Spiceworks Community

  • Oracle sql*plus encountered a problem and needs to be closed

    hello all,
    actually many times on internet i red that this is classic windows error, while looking for resolution to this error.....but there are many reasons specified......some says virus, some says multiple oracle homes, some says PATH environment variable....i searched net a lot for this error but no specific resolution found....
    but i am almost unable to understand reason in my scenario...my set up is as follows:
    OS:- windows XP SP2
    database:- oracle database XE
    other:- D2K6i (installed in its own home
    environmental variable set :- PATH with D2K6i and oracle XE home
    i alos tried setting ORACLE_HOME variable to XE oracle home but no luck
    i tried almost all trick to resolve this issue, my sqlplus in oracle XE home is not opening ....it just blink and then disappear..when i type sqlplus in run dialog box it opens the sqlplus of D2K6i....and anti virus software is updated on that machine..
    and when i tried to connect to XE on same machine..then it is generating this error with window and that useless "Don't send" window error....
    what might be the reason???? i have tried almost all tricks....any other change need to be done??
    any suggestion is appreciable???
    thanks and regards
    VD
    Edited by: dixit on Aug 24, 2009 9:57 PM
    Edited by: dixit on Aug 24, 2009 9:58 PM

    hello satish sir,
    i resolved the issue, i repaired the XE installation with XE universal installer, i don't know what was the issue but it is now working....
    thanks for your kind support...
    thanks and regards
    VD

  • I am in retail and have multiple subsiduaries to report on. All articles. What report can I run or create. I have listed below details that need to be shown.

    Article number, description, unit of measure for each article, unit of issue, units on order, current stock on hand, merchandise dept, stock planner id, current value of stock on hand in local currency, Thankyou

    This can be a problem with the file places.sqlite that stores the bookmarks and the history.
    * http://kb.mozillazine.org/Bookmarks_history_and_toolbar_buttons_not_working_-_Firefox

  • SQL*PLUS 32 Bit Client needed for Windows 64 Bit

    Hi,
    I have got a 64 Bit Windows OS and an Oracle 11.
    With 32 Bit Applications ( Crystal Reports) I can not run SQL NET Thick, SQL NET Thin and JDBC.
    Oracle 32 Bit Installation is Missing.
    Oracles "Instant Client Downloads for Microsoft Windows (32-bit)" will not do it.
    http://www.oracle.com/technetwork/topics/winsoft-085727.html
    What else to use ?
    Thank You
    Martin Sautter

    Martin.Sautter wrote:
    Hi,
    i used:
    instantclient-basic-nt-11.2.0.2.0.zip (32BitClient)
    instantclient-sqlplus-nt-11.2.0.2.0.zip.
    I did not find an "old", "classic" SQL*PLUs client.What does that mean exactly, classic client?
    Did you unzip the ic sqlplus .zip (the one listed) in the same dir as ic basic?
    After dezipping waht than ?
    No installer, nothing ...That's the beauty of Instant Client, just unzip or move a few files, set PATH if needed, and you have client libraries all "installed" and ready.
    >
    You can give advice ?Generally, required lib files are (n Windows) oci.dll, oraociicusN.dll or oraocieiN.dll (N= e.g. 11). Then for Sql*plus add orasqlplusicN.dll and the .exe from ic-sqlplus package.
    C:\Users\Test\Ora-IClite>dir
    Volume in drive C is OS
    Volume Serial Number is 6E8F-186A
    Directory of C:\Users\Test\Ora-IClite
    2011-12-16  09:30    <DIR>          .
    2011-12-16  09:30    <DIR>          ..
    2011-08-31  11:39                38 ldap.ora
    2011-07-30  12:21           683 008 oci.dll
    2011-07-30  12:21        44 153 856 oraociicus11.dll
    2011-07-30  12:21         1 501 696 Orasqlplusic11.dll
    2011-07-30  12:21           869 376 sqlplus.exe
    C:\Users\Test\Ora-IClite>.\sqlplus user@'localhost/xe'
    SQL*Plus: Release 11.2.0.2.0 Production on Fri Dec 16 09:34:13 2011
    Copyright (c) 1982, 2010, Oracle.  All rights reserved.
    Enter password:Edited by: orafad on Dec 16, 2011 9:35 AM

  • Insert more than 4000 characters using sql plus

    I have a SQL script that creates a database. The problem is that some of the fields are longer than 4000 characters in the INSERT statement and Oracle doesn't seem to like it.
    The field is a clob and works fine in the application (i.e. I can insert more than 4000 characters using the app) - how do I achieve this in a SQL script?
    Any help is much appreciated.
    Cheers,
    Steve

    Hi,
    This pl/sql block works absolutely fine in SQL*Plus inserting > 4000 characters into clob column:
    declare
    l_str varchar2(8000);
    l_str1 varchar2(2400) := 'first part of the verly long string...';
    l_str2 varchar2(2400) := 'second part of the verly long string...';
    begin
    l_str := l_str1 || l_str2;
    insert into tmpl values (l_str);
    end;
    So, you'll have to replace inserts with pl/sql blocks in your script.
    Tested in Oracle 8.1.7.0.0
    Regards,
    Andrew Velitchko
    BrainBench MVP for Developer/2000
    http://www.brainbench.com

  • Semicolon and / in SQL Plus scripts?

    Anyone,
    Seem to have some confusion over the use of / and ; inside PL SQL Scripts run in SQL Plus.
    I seem to get two commits thereby two rows on INSERT clase that has a ; and a /.
    i.e.
    /* Insert record into table for recording statistics on the runtime of this script */
    INSERT INTO MYTABLE ( col1, col2) VALUES ( value1, value2);
    COMMIT;
    /The above will get two of the same rows in the table. Is this an issue with SQL Plus settings? What do people typically use? I have a combination of SQL and DDL in my scripts and I need / for the DDL typically as I understand. How do othere intermix these and what standard is used.

    Dave, here are the very basics.
    The SQL language does not have command separators as only a single command at a time can be issued. Thus the following is invalid SQL:
    SELECT * FROM emp;
    The semicolon as command separator (or terminator) is not valid SQL. This is valid SQL:
    SELECT * FROM emp
    PL/SQL is a programming language similar to Pascal, C and Java. Multiple commands are used in a program. These need to be separated so that the parser/compiler can know where a command starts and where it ends. In PL/SQL the semicolon is used.
    The following is invalid PL/SQL as it is missing command separators:
    declare
    i integer
    begin
    i := 1234
    endThe following is valid PL/SQL :
    declare
    i integer;
    begin
    i := 1234;
    end;SQL*Plus is an Oracle CLI (command line interface) client. It can submit both SQL and PL/SQL to the database. It needs to know when you have stopped entering commands into its input buffer and to submit what you've entered to the database.
    SQL*Plus uses two characters for this. The semicolon and the forward slash. If you want to submit the above SELECT to Oracle using SQL*Plus, SQL*Plus needs to know when to submit its input buffer's content - thus:
    SQL> SELECT * FROM emp;
    Or:
    SQL> SELECT * FROM emp
    SQL> /
    When using PL/SQL in SQL*Plus, SQL*Plus "understands" that the semicolons you use are for the PL/SQL language - not an instruction from you to it to submit its buffer to Oracle for execution.
    The forward slash can also be at anytime used to resubmit the current SQL*Plus input buffer again. E.g.
    SQL> SELECT * FROM emp;
    .. now do the last SQL (or PL/SQL) in the buffer again
    SQL> /[i]

  • 8.1.7: ORA-01410 in PL/SQL but not SQL*Plus

    This has been driving me crazy, and a search here and in comp.databases.oracle didn't turn up any solutions.
    When the following code is part of a stored procedure, it fails with ORA-01410 (Invalid ROWID). It executes perfectly from SQL*Plus, I've verified that TMP_TASK_DATA contains data, and the query clearly specifies a ROWID.
    As noted in the subject, this occurs on 8.1.7. TMP_TASK_DATA and TMP_TASK_RETRIEVAL are both global temp tables. I don't currently have access to Metalink, so was hoping that someone has run across this and has some hints.
    Thx,
    (query edited to limit "IN" list):
            INSERT  INTO TMP_TASK_RETRIEVAL
                    (TASK_ID, TD_ROWID, SORT_ORDER)
            SELECT  TASK_ID, TD_ROWID, ROWNUM
            FROM    (
                    SELECT  TASK_ID, TD_ROWID
                    FROM    (
                            SELECT  TASK_ID,
                                    ROWID                                   as TD_ROWID,
                                    SF_GET_PRIORITY(TASK_TYPE, 1 )          as PRIORITY_COMM,
                                    COMPLETED_TIME                          as FINISH_TIME,
                                    FIRST_READY_TIME                        as QUEUE_TIME
                            FROM    TMP_TASK_DATA
                            WHERE   USER_NUMBER = v_USER_NUM
                            AND     TASK_TYPE in
                                    'AAAA', 'BBBB', 'CCCC'
                    ORDER BY
                            PRIORITY_COMM,
                            decode(PRIORITY_COMM, 10, FINISH_TIME, QUEUE_TIME)
                    );

    Thanks for the info. It turned out that I was wrong about removing the PL/SQL variable from the query; either that, or the error occurs at arbitrary times.
    As best I can tell, a ROWID simply can't be passed between nested inline views, so I reduced them to one level (which means that I have to run the function twice in the ORDER BY, rather than once in the nested select).

  • SQL*Plus variable assignment works for 8i but not 9i

    We have scripts that connect to each database on the box and perform database tasks nightly. The scripts first set the environment then connects to each database with SQL*Plus. This works for 8i but fails in the recently created 9i environment. (Unix Solaris environment)
    Because the SQL*Plus connection appears in many areas in the scripts, we assign the following connection string to a variable:
    SQLPLUS="/usr/oracle/product/9.2.0/bin/sqlplus -s 'xxx/xxxxxx@xxxx as sysdba'"
    Export SQLPLUS
    echo "$SQLPLUS"
    (This echo out correctly: /usr/oracle/product/9.2.0/bin/sqlplus -s 'xxx/xxxxxx@xxxx as sysdba')
    It fails when the script calls the assigned variable:
    $SQLPLUS <<-EOF
    with the following error:
    Usage: SQLPLUS [ [<option>] [<logon>] [<start>] ]
    where <option> ::= -H | -V | [ [-L] [-M <o>] [-R <n>] [-S] ]
    <logon> ::= <username>[<password>][@<connect_string>] | / | /NOLOG
    <start> ::= @<URI>|<filename>[.<ext>] [<parameter> ...]
    "-H" displays the SQL*Plus version banner and usage syntax
    "-V" displays the SQL*Plus version banner
    "-L" attempts log on just once
    "-M <o>" uses HTML markup options <o>
    "-R <n>" uses restricted mode <n>
    "-S" uses silent mode
    However, if I remove the SQLPLUS variable assignment and changed all occurrence of
    $SQLPLUS <<-EOF to
    /usr/oracle/product/9.2.0/bin/sqlplus -s 'xxx/xxxxxx@xxxx as sysdba' <<-EOF
    Then the script runs successfully. But this solution is cumbersome.
    Any ideas as to how to have the script work with assigning the SQLPLUS variable????
    Any help is appreciated.

    I has an immediate suspicion it might be related to the issue
    mentioned in
    http://otn.oracle.com/support/tech/sql_plus/htdocs/sub_var2.html#2_7
    but this proved wrong: the SP2-306 still occurs in the latest
    SQL*Plus.
    I wonder what version of 8i you had working? With an old SQL*Plus
    8.1.7.0 my connection failed the same as in 9.2 and 10i.
    My solution was to do:
      SQLPLUS='sqlplus -s'
      UNPW='/ as sysdba'
      $SQLPLUS "$UNPW" &lt;&lt;EOF
      EOFThis worked in 9.2.0.5, 10.1.0.2 and 8.1.7.0.
    One common security risk on UNIX remains: putting the username and
    password on the command line. On some systems a "ps" command will
    show the password to any user. If OS authentication cannot be used
    for connection, perhaps putting the username/password in the SQL
    script may be more secure?
    A final note is that in SQL*Plus 10g, no quotes are needed around
    AS SYSDBA, i.e.
      sqlplus / as sysdba works from the OS prompt, whereas in 9.2 you need to do
      sqlplus "/ as sysdba"This makes a solution easy:
      SQLPLUS="/usr/oracle/product/10.1.0/bin/sqlplus -s xxx/xxxxxx@xxxx as sysdba"-- CJ

  • SQL*Plus assignment works for 8i but not 9i

    We have scripts that connect to each database on the box and perform database tasks nightly. The scripts first set the environment then connects to each database with SQL*Plus. This works for 8i but fails in the recently created 9i environment.
    Because the SQL*Plus connection appears in many areas in the scripts, we assign the following connection string to a variable:
    SQLPLUS="/usr/oracle/product/9.2.0/bin/sqlplus -s 'xxx/xxxxxx@xxxx as sysdba'"
    Export SQLPLUS
    echo "$SQLPLUS"
    (This echo out correctly: /usr/oracle/product/9.2.0/bin/sqlplus -s 'xxx/xxxxxx@xxxx as sysdba')
    It fails when the script calls the assigned variable:
    $SQLPLUS <<-EOF
    with the following error:
    Usage: SQLPLUS [ [<option>] [<logon>] [<start>] ]
    where <option> ::= -H | -V | [ [-L] [-M <o>] [-R <n>] [-S] ]
    <logon> ::= <username>[<password>][@<connect_string>] | / | /NOLOG
    <start> ::= @<URI>|<filename>[.<ext>] [<parameter> ...]
    "-H" displays the SQL*Plus version banner and usage syntax
    "-V" displays the SQL*Plus version banner
    "-L" attempts log on just once
    "-M <o>" uses HTML markup options <o>
    "-R <n>" uses restricted mode <n>
    "-S" uses silent mode
    However, if I remove the SQLPLUS variable assignment and changed all occurrence of
    $SQLPLUS <<-EOF to
    /usr/oracle/product/9.2.0/bin/sqlplus -s 'xxx/xxxxxx@xxxx as sysdba' <<-EOF
    Then the script runs successfully. But this solution is cumbersome.
    Any ideas as to how to have the script work with assigning the SQLPLUS variable????
    Any help is appreciated

    I has an immediate suspicion it might be related to the issue
    mentioned in
    http://otn.oracle.com/support/tech/sql_plus/htdocs/sub_var2.html#2_7
    but this proved wrong: the SP2-306 still occurs in the latest
    SQL*Plus.
    I wonder what version of 8i you had working? With an old SQL*Plus
    8.1.7.0 my connection failed the same as in 9.2 and 10i.
    My solution was to do:
      SQLPLUS='sqlplus -s'
      UNPW='/ as sysdba'
      $SQLPLUS "$UNPW" &lt;&lt;EOF
      EOFThis worked in 9.2.0.5, 10.1.0.2 and 8.1.7.0.
    One common security risk on UNIX remains: putting the username and
    password on the command line. On some systems a "ps" command will
    show the password to any user. If OS authentication cannot be used
    for connection, perhaps putting the username/password in the SQL
    script may be more secure?
    A final note is that in SQL*Plus 10g, no quotes are needed around
    AS SYSDBA, i.e.
      sqlplus / as sysdba works from the OS prompt, whereas in 9.2 you need to do
      sqlplus "/ as sysdba"This makes a solution easy:
      SQLPLUS="/usr/oracle/product/10.1.0/bin/sqlplus -s xxx/xxxxxx@xxxx as sysdba"-- CJ

  • DB in WXP, SQL/PLUS in WXP too

    Hello ORACLE'rs:
    First, sorry if I'm posting in the wrong place [this is my first in this forum]; is some of the admins/moderators believe this thread should be moved, please go ahead.
    Well, this is my question/issue:
    We have our Oracle 9i DB in a Sun Solaris server at work; we basically use SQL PLUS or Oracle PLSQL Developer to program/edit our scripts.
    I would like to use the same environment at home using WINDOWS XP; I want to develop at home, but I dont' have a Solaris server I can use, so I need to setup a DB in my WXP machine at home. Of course, I'll be using SQL PLUS to work on that DB at home.
    What DB version should I download, take home, install and use?
    Is there a place in the oracle OTN site or this forum that has info on this??
    Thanks in advance
    Alfonso Sanchez

    Thanks GFPIKE, this seems to be just what I need:
    Developers working on PHP, Java, .NET, XML, and Open Source applications
    DBAs who need a free, starter database for training and deployment
    Independent Software Vendors (ISVs) and hardware vendors who want a starter database to distribute free of charge
    Educational institutions and students who need a free database for their curriculum
    For now I just want it for my PL/SQL development.
    "In this theather that I call my soul I always play the starring role" - THE POLICE
    Alfonso Sanchez - www.imperial.edu

Maybe you are looking for

  • Reinstall After Hard Drive Errors

    The system restore from the hard drive is a great idea except when your hard drive is dropping bad sectors left and right.  One of my clients bought a 3000 Desktop with Windows Vista Business 13 months ago.  I got the call that the system wouldn't bo

  • How do I add effects on the new garage band

    On the old garage band i could double click on a track and i had a side bar of effect such as: Reverb Distortion Overdrive In the new update it appears they have gotten rid of this and i wondered if there is still a way of doing it. Please help. Than

  • Saving a file in JSF with a servlet

    Okay, here is essentially what I'm doing right now: 1. The user selects some data that they want to export (save) to a file and enters a filename into a text box. 2. The user then clicks an 'Export' button and a controller action is invoked that puts

  • Simulation Of ADFC-12003 in integerated weblogic server

    Hi all I have developed a web application it is working fine with integreated weblogic server but when i deploy it in weblogic server clustered environment it is throwing following error Caused By: oracle.adf.controller.ControllerException: ADFC-1200

  • Execution of Immediate SQL in compiled package in two versions of SQL*PLUS

    A peculiar problem has risen in our database. Execution of Immediate SQL in compiled package in two versions of SQLPLUS gives different results We have a compiled package with two procedures that contain immediate SQL statements, and these are: +PROC