10-10-2012
I can't read nor interpret the error msg, but I would be very curious where that "char" is coming from. The value is way beyond the UTF-32 code set, so how did it enter the DB in the first place? Maybe the input routines need some more error checking?
9 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
Hi All,
How to remove a box like special character which appears at the end of a string/line/record. I have no clue what this box like special character is. It is transparent square like box. This appears in a .DAT file at the end of header.
I'm to compare a value in header with a parameter.... (16 Replies)
Discussion started by: Qwerty123
16 Replies
2. Shell Programming and Scripting
Can someone help me to write a script / command to read in a file, character by character, replace any unknown ASCII characters with space. then write out the file to a new filename/
Thanks! (1 Reply)
Discussion started by: raghav525
1 Replies
3. Shell Programming and Scripting
Can any one plse help me writing shell script to removing some special character pattern (like / > -------, / > / > ------- etc....as shown below) from the text file ASAP.
/ > -------
<tag-normalization tag-name="EXECSERVPRODUCT" read-only="false" part="body">
... (3 Replies)
Discussion started by: bkc
3 Replies
4. Shell Programming and Scripting
Hello ,
i have a text file like this :
A123 c12AB c32DD aaaa
B123 23DS 12QW bbbb
C123 2GR 3RG cccccc
i want to remove the numbers from second and third column only.
i tried this :
perl -pe 's///g' file.txt > newfile.txt
but it will remove the number from... (7 Replies)
Discussion started by: shelladdict
7 Replies
5. Shell Programming and Scripting
Hello
I've searched here and on the 'net for examples of a script or command line function that will remove the $ character from all file names only that can be done within the directory that contains the file names - which are all html files.
ie, I have a directory that contains html files... (6 Replies)
Discussion started by: competitions
6 Replies
6. UNIX for Dummies Questions & Answers
Hi Guru,
I have put one post yesterday and get answer. thanks for your help.
my question today is: what is ascii character for following non printable characters: ( we need filter these characters out in another process)
^MM-^E^MM-^E.
Old post link: ... (5 Replies)
Discussion started by: ken002
5 Replies
7. Shell Programming and Scripting
Hi Folks,
I have a huge data of the below format
abc #apple 1200 06/23
ghj #orange 1500 06/27
uyt #banana 2300 05/13
efg #vegetable 0700 04/16
After first 3 letters, i have 9 spaces and after fruit there are no specific fixed space, but it varies... (4 Replies)
Discussion started by: jayadanabalan
4 Replies
8. Shell Programming and Scripting
Hi There,
I have one requirement to remove word after character "/".
Input file is
2017-07-12|02|user1l|domain1/userl|0
2017-07-12|02|user2|domain1/user2|5
2017-07-12|02|user3|domain2/user3|0
2017-07-12|02|user4|domain1/user4|432
and require OP file is
... (2 Replies)
Discussion started by: anshu ranjan
2 Replies
9. UNIX for Beginners Questions & Answers
Hi all.
I want to use sed to remove a word that ends with "!" in the first page of a file. The word I want to remove is: "DNA!".
I have search for an answer and nothing of what I found helped me.
~faizlo (2 Replies)
Discussion started by: faizlo
2 Replies
LEARN ABOUT HPUX
xseterrorhandler
XSetErrorHandler() XSetErrorHandler()
Name
XSetErrorHandler - set a fatal error event handler.
Synopsis
int (*XSetErrorHandler(handler))()
int (* handler)(Display *)
Arguments
handler The user-defined function to be called to handle error events. If a NULL pointer, reinvoke the default handler, which prints a
message and exits.
Returns
The previous nonfatal error handler.
Description
The error handler function specified in handler will be called by Xlib whenever an XError event is received. These are nonfatal condi-
tions, such as unexpected values for arguments, or a failure in server memory allocation. It is acceptable for this procedure to return,
though the default handler simply prints a message and exits. However, the error handler should NOT perform any operations (directly or
indirectly) that generate protocol requests or that look for input events.
In Release 4 and Release 5, XSetErrorHandler() returns a pointer to the previous error handler.
The function is called with two arguments: the display variable and a pointer to the XErrorEvent structure. Here is a trivial example of
a user-defined error handler:
int myhandler (display, myerr)
Display *display;
XErrorEvent *myerr;
{
char msg[80];
XGetErrorText(display, myerr->error_code, msg, 80);
fprintf(stderr, "Error code %s
", msg);
}
This is how the example routine would be used in XSetErrorHandler():
XSetErrorHandler(myhandler);
Note that XSetErrorHandler() is one of the few routines that does not require a display argument. The routine that calls the error handler
gets the display variable from the XErrorEvent structure.
The error handler is not called on BadName errors from OpenFont, LookupColor, and AllocNamedColor protocol requests, or on BadFont errors
from a QueryFont protocol request. These errors are all indicated by Status return value of zero in the corresponding Xlib routines, which
must be caught and handled by the application.
Use XIOErrorHandler to provide a handler for I/O errors such as network failures or server host crashes.
In the XErrorEvent structure shown below, the serial member is the number of requests (starting from 1) sent over the network connection
since it was opened. It is the number that was the value of the request sequence number immediately after the failing call was made. The
request_code member is a protocol representation of the name of the procedure that failed and is defined in <X11/Xproto.h>.
For more information, see Volume One, Chapter 3, Basic Window Program.
Structures
typedef struct {
int type
Display *display; /* display the event was read from */
XID resourceid; /* resource ID */
unsigned long serial; /* serial number of failed request */
unsigned char error_code; /* error code of failed request */
unsigned char request_code; /* major opcode of failed request */
unsigned char minor_code; /* minor opcode of failed request */
} XErrorEvent;
See Also
XDisplayName(), XGetErrorDatabaseText(), XGetErrorText(), XSetAfterFunction(), XSetIOErrorHandler(), XSynchronize().
Xlib - Error Handling XSetErrorHandler()