Sponsored Content
Full Discussion: Split Command options
Top Forums UNIX for Advanced & Expert Users Split Command options Post 302091599 by mohdtausifsh on Wednesday 4th of October 2006 01:21:04 AM
Old 10-04-2006
Split Command options

HI! All
iam using Split command to split a large .txt file in to smaller files,

The syntax iam using
split -25000 Product.txt

iam getting four output files but not in .txt format but in some other format ,
when i checked the properties the Type of the output files is Type

can any one help me in this
 

9 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

how to? launch command with string of command line options

my description from another thread... here's my code: #!/bin/bash IFS=$'\n' function OutputName() { input=$1 echo $input input=`echo "$input" | sed -e 's/.//'` input=`echo "$input".avi` output_name=$input } if ]; then echo... (5 Replies)
Discussion started by: TinCanFury
5 Replies

2. HP-UX

Linux - HP UX Command options

Just I gone with the script, I found some command's options which are not compatible with " HP-UX ". If I found any alternate commands to the following, most probably I will solve the issue here. 1. " iostat -x " --> this command's option( x ) is not available in HP-UX... (2 Replies)
Discussion started by: pk_eee
2 Replies

3. Shell Programming and Scripting

Restricting the ls command options

Hi I want the 'ls' command to display only the file size,date modified and name of the file.What i could see with different options is this: $ls -got packagecount.csv $-rwxrwxrwx 1 393137 Aug 21 14:46 packagecount.csv Now what should be my possible... (4 Replies)
Discussion started by: sushovan
4 Replies

4. Shell Programming and Scripting

Need to disable options from a command

Hi, I am working on a Linux machine. I need to disable 2 options from the available 6 options of a command. For eg. in the "ls" command we have various options like "l ,r, t, a, .... " From this, I need to disable option "a" So when the users type in "ls -a", they should get an error or... (4 Replies)
Discussion started by: aster007
4 Replies

5. UNIX for Dummies Questions & Answers

Running set options from the command line and bash command

I'm reading about debugging aids in bash and have come across the set command. It says in my little book that an addition to typing set you can also use them "on the command line when running a script..." and it lists this in a small table: set -o option Command Line... (5 Replies)
Discussion started by: Straitsfan
5 Replies

6. UNIX for Dummies Questions & Answers

Override options of rm command

How can i override options of rm command ?? and how can i implement my own options when we delete file using rm commad it will not delete file it has to move some folder....plz suggest some solution. (10 Replies)
Discussion started by: arun508.gatike
10 Replies

7. Shell Programming and Scripting

Reading command options one by one

Hi, Just some questions on the script below...? Given: bash-2.03$ command -a option1 name1 name2 ParseOptions() { local Len=${#@} local Ctr=2 #always start at 2 local Name=() local Iter=0 while ; do if <- Is this correct? so I can get the $2... (2 Replies)
Discussion started by: h0ujun
2 Replies

8. Shell Programming and Scripting

Help executing command with options

Hi, I have this command in a shell script and I can get it to echo ok, but when I try to execute the command I get a "file not found" error. Which is strange because, if I copy and paste the same command at the cli it works ok. What am I doing wrong please? (16 Replies)
Discussion started by: bbbngowc
16 Replies

9. UNIX for Beginners Questions & Answers

Ls command options

Hi, If I want to list files with names containing a certain letter like " a " using just one ls command, is there any way of doing that? Note that it is containing a letter instead of one of the following (starting, ending with a letter or having the letter in between). what I want is to show... (1 Reply)
Discussion started by: AAAnni
1 Replies
split(1)						      General Commands Manual							  split(1)

NAME
split - Splits a file into pieces SYNOPSIS
Current syntax split [-l line_count] [-a suffix_length] [file | -] [prefix] split -b n [k|m] [-a suffix_length] [file | -] [prefix] Obsolescent syntax split [-number] [-a suffix_length] [file | -] [prefix] STANDARDS
Interfaces documented on this reference page conform to industry standards as follows: split: XCU5.0 Refer to the standards(5) reference page for more information about industry standards and associated tags. OPTIONS
Uses suffix_length letters to form the suffix portion of the file names of the split file. If -a is not specified, the default suffix length is two letters. If the sum of the prefix and the suffix arguments would create a file name exceeding NAME_MAX bytes, an error occurs. In this case, split exits with a diagnostic message and no files are created. Split a file into pieces n bytes in size. Split a file into pieces n kilobytes (1024 bytes) in size. Split a file into pieces n megabytes (1048576 bytes) in size. Specifies the number of lines in each output file. The line_count argument is an unsigned decimal integer. The default value is 1000. If the input does not end with a newline character, the partial line is included in the last output file. Specifies the number of lines in each output file. The default is 1000 lines per output file. If the input does not end with a newline character, the partial line is included in the last output file. (Obsolescent) OPERANDS
The pathname of the file to be split. If you do not specify an input file, or if you specify -, the standard input is used. DESCRIPTION
The split command reads file and writes it in number-line pieces (default 1000 lines) to a set of output files. The size of the output files can be modified by using the -b or -l options. Each output file is created with a unique suffix consisting of exactly suffix lowercase letters from the POSIX locale. The letters of the suffix are used as if they were a base-26 digit system, with the first suffix to be created consisting of all a characters, the second with b replacing the last a etc., until a name of all zs is cre- ated. By default, the names of the output files are x, followed by a two-character suffix from the character set as described above, starting with aa, ab, ac, etc., and continuing until the suffix zz, for a maximum of 676 files. The value of prefix cannot be longer than the value of NAME_MAX from <limits.h> minus two. If the number of files required is greater than the maximum allowed by the effective suffix length (such that the last allowable file would be larger than the requested size), split fails after creating the last possible file with a valid suffix. The split command will not delete the files it created with valid suffixes. If the file limit is not exceeded, the last file created contains the remainder of the input file and thus might be smaller than the requested size. EXIT STATUS
The following exit values are returned: Successful completion. An error occurred. EXAMPLES
To split a file into 1000-line segments, enter: split book This splits book into 1000-line segments named xaa, xab, xac, and so forth. To split a file into 50-line segments and specify the file name prefix, enter: split -l50 book sect This splits book into 50-line segments named sectaa, sectab, sectac, and so forth. ENVIRONMENT VARIABLES
The following environment variables affect the execution of split: Provides a default value for the internationalization variables that are unset or null. If LANG is unset or null, the corresponding value from the default locale is used. If any of the internationalization vari- ables contain an invalid setting, the utility behaves as if none of the variables had been defined. If set to a non-empty string value, overrides the values of all the other internationalization variables. Determines the locale for the interpretation of sequences of bytes of text data as characters (for example, single-byte as opposed to multibyte characters in arguments and input files). Determines the locale for the format and contents of diagnostic messages written to standard error. Determines the location of message catalogues for the processing of LC_MESSAGES. SEE ALSO
Commands: bfs(1), csplit(1) Standards: standards(5) split(1)
All times are GMT -4. The time now is 06:09 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy