06-24-2005
Search for
"here-document" in this site.
10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
Hi,
I'd like to access a windows directory from aix with samba client.
To allow direct access (not interactive), i'm using EOF like:
smbclient \\\\winserver\\windir 'passwd' -U usersmb << EOF
cd subwindir
put myfile
EOF
The access is correct but does somebody know how to trap errors... (1 Reply)
Discussion started by: jo_aze
1 Replies
2. Shell Programming and Scripting
How to check for a premature EOF in a regular file in a shell/perl script?
I want to check if I have received a complete file or not.
Thanks,
Rahul. (12 Replies)
Discussion started by: rahulrathod
12 Replies
3. UNIX for Dummies Questions & Answers
hello all,
how end of a file is detected in UNIX system?
does it make use of any special symbols to identify the EOF? :(
thank you all (5 Replies)
Discussion started by: compbug
5 Replies
4. UNIX for Dummies Questions & Answers
I have written this code:
code
echo 'Now choose the file or files you want to merge your input with: \c'
read filenames
filelist=""
for file in $filenames; do
filelist="$filelist $file"
done
echo "Now that you've chosen these files ($filelist), please start typing: "
until ; do
paste -... (2 Replies)
Discussion started by: fiol73
2 Replies
5. Shell Programming and Scripting
hi,
in a shell script i came accross the following bit of code
1.shift $(($OPTIND - 1))
2.if ; then
3. cat << EOF >&2
4.Usage: $0 lockfilename
5.EOF
6. exit 1
7.fi
I am not able to understand the meaning of lines(1,3,5).
Can any one of u tell me the purpose of above said lines.... (1 Reply)
Discussion started by: ravi raj kumar
1 Replies
6. UNIX for Dummies Questions & Answers
Hello all,
I have unix file that ends with the following EOF '9999999999'
I want to remove the '\n' character after EOF. What is the command that should be included in the script, before sending the file?
will this work:
$ echo "<99999999999>\c" >> <filename>
thanks in advance. (3 Replies)
Discussion started by: priya12
3 Replies
7. Shell Programming and Scripting
I'm trying to connect to oracle with the following code in the script:
checksqlerror{
if
echo $1
exit
fi
}
$SQLPLUS username/password@schemaname
checksqlerror "failed to connect to oracle"
If I'm passing wrong schema name,instead of executing checksqlerror it stops and expects user... (2 Replies)
Discussion started by: BhawanaAggarwal
2 Replies
8. Programming
How can I write EOF into a file?
I tryed to do as follows:
size=sizeof(EOF);
end_of_file=EOF;
write(fdMutexRichieste, &end_of_file, size);
But it does non work correctly,
becouse in the next cicle (using lseek(..., SEEK_END) of my code it seems to ignore my EOF and use the LAST... (5 Replies)
Discussion started by: DNAx86
5 Replies
9. Shell Programming and Scripting
Hey!
Can I write a routine that allows me to in a txt file check line by line until the end of file?
something like
until do
---some code---
done
maybe it is a stupid question but I never learned shell scripts and I need this :p
thanks in advance (1 Reply)
Discussion started by: ruben.rodrigues
1 Replies
10. Shell Programming and Scripting
Hi friends ,
I am confused with << EOF
EOF
Most of the cases I found
sqlplus $db_conn_str << EOF
some sql staments
EOF
another exapmle is
#!/bin/sh
echo -n 'what is the value? '
read value
sed 's/XXX/'$value'/' <<EOF
The value is XXX
EOF (1 Reply)
Discussion started by: imipsita.rath
1 Replies
LEARN ABOUT DEBIAN
search::xapian::document
Xapian::Document(3pm) User Contributed Perl Documentation Xapian::Document(3pm)
NAME
Search::Xapian::Document - Document object
DESCRIPTION
This class represents a document in a Xapian database.
METHODS
new Class constructor.
clone
Return a clone of this class.
get_value (value_no)
Returns the value by the assigned number.
add_value <value_no> <value>
Set a value by value number.
remove_value <value_no>
Removes the value with the assigned number.
clear_values
Clear all set values.
get_data
Return all document data.
set_data <data>
Set all document data. This can be anything you like.
add_posting <term> <position> [<weight>]
Adds a term at the given position. weight defaults to 1.
remove_posting <term> <position> [<weight]
Removes a term from the given position. weight defaults to 1.
add_term <term> [<weight>]
Adds a term without positional information. weight defaults to 1.
add_boolean_term <term>
Adds a term intended for boolean filtering (its wdf contribution will be 0).
remove_term <term>
Removes a term without positional information.
clear_terms
Remove all terms from the document.
termlist_count
Returns number of terms in the document.
termlist_begin
Iterator for the terms in this document. Returns a Search::Xapian::TermIterator.
termlist_end
Equivalent end iterator for termlist_begin(). Returns a Search::Xapian::TermIterator.
values_count
Return number of defined values for this document.
values_begin
Return a Search::Xapian::ValueIterator pointing at the start of the values in this document.
values_end
Return a Search::Xapian::ValueIterator pointing at the end of the values in this document.
get_description
Return a description of this object.
SEE ALSO
Search::Xapian::Database
perl v5.14.2 2012-05-09 Xapian::Document(3pm)