Hi,
Is there a way I can extract my data faster. You know my data is 1.2 GB text file with 8Million rows with 38 columns/fields. Imagine how huge this is.
How I can optimized the data extraction using perl. That is why I'm creating a script to filter only those informations that I need. Is... (3 Replies)
Hi,
I want to extract some part of a pattern that matches my requirement in a string with PERL. A case in point is a string like:
$eqtst="abh nmae res = 10 s abh nmae req = 10 s";
from which I want the words preceding the "=" symbol.
Previously I was assured that there would be only 2 such... (4 Replies)
I have a string stored in a variable. For instance,
$str = " Opcode called is : CM_OP_xxx "
where xxx changes dynamically and can be either LOGIN or SEARCH..... depends on runtime.
For example :
$str = " Opcode called is : CM_OP_SEARCH "
$str = " Opcode called is : CM_OP_LOGIN "
I... (3 Replies)
the log contains mathematical operation as follows
fm_void_mathematics : PCM_OP_MATHS input function
PIN_FLD_NUM1 INT 1
PIN_FLD_NUM2 INT 2
PIN_FLD_RESULTS int
PIN_FLD_OUT INT *
D Wed Sep 16 05:40:22 2009 solaris_testing
fm_void_add :
PIN_FLD_SUM int 3
D Wed Sep 16 05:40:22 2009... (1 Reply)
HI,
i have variable in perl like below
$tmp="/home/sai/automation/work/TFP_GN.txt"
it can conatain any path its filled from config file.
now i want extarct the path upto this /home/sai/automation/work/ and put it in another variable
say... (4 Replies)
Hello,
I want to extract the words from a file which starts with SRD-R or SRD-DR.
I have written a script which is able to trace the word but it is printing the whole line.
sub extract_SRD_tag{
my ($tag, $app, $path, @data, $word );
$path = shift;
$app = shift;
open (FILE, $path) or... (2 Replies)
Hi,
I am using the following code to retrieve the contents between C-style comments "/* .. */".
perl -lne 'while(/(\/\*.*?\*\/)/g) {print "$1";}'
This works fine when the commented section of code is present in a single line. But I also need to extract the data which is present inside... (3 Replies)
Dear all,
I find a perl script that contains the following codes. Does anybody know the meaning of codes highlight.
.....
@field = parse_csv($file);
chomp(@field);
........
........
sub parse_csv {
my $text = shift;
my @new = ();
push( @new, $+ ) while $text =~ m{... (9 Replies)
Hi, I need to extract Password expires from the output of windows command print `net user %USERNAME% /domain`; in perl. So i want to redirect the output of this win-cmd to a file and try extracting Password expires along with its value. i'm trying with this code but getting errors.
#!usr/bin/perl... (1 Reply)
I am working on converting shell to Perl script. In shell we have built in function
trap
Do you know alternative in Perl or actually we don't need it?
Thanks for contribution (3 Replies)
Discussion started by: digioleg54
3 Replies
LEARN ABOUT OSX
buildstrings
BuildStrings(1) BSD General Commands Manual BuildStrings(1)NAME
/usr/bin/BuildStrings -- Generate header (.h) or resource (.r) file from text files
SYNOPSIS
/usr/bin/BuildStrings [-define variable] [-header] [-attributes attributeList] [-type filekind] -id ResID -in path -out path
DESCRIPTION
The /usr/bin/BuildStrings command translates a text file into a resource or header file for use in localizing your Carbon application. The
input file is a series of newline-separated pairs of newline-separated strings. Each pair of strings represents the "base" string and the
localized equivalent. When generating a resource file, /usr/bin/BuildStrings generates a STR# resource containing only the localized equiva-
lents (which must be enclosed in double quotes in the source file). When generating the header file, /usr/bin/BuildStrings generates a C
header file with #define directives for each of the base strings (which must be valid C preprocessor symbols) equating each to the ordinal
number of the string in the STR# resource. Your C/C++ source code can use these preprocessor macros, along with standard Resource Manager
calls (like GetIndString) to load the appropriate localized string.
The source file may include #ifdef/#endif (or #ifndef/#endif) directives to conditionally include different pairs of strings, e.g. for debug-
ging builds or different versions. Note that these are the only preprocessor directives allowed in the source file.
When generating a resource file, you can set the resource ID and attributes of the STR# resource by providing /usr/bin/BuildStrings with the
appropriate command-line options.
You can use /usr/bin/BuildStrings with several different sets of strings in the same application, for example, error strings and warning
strings. The -type argument customizes some #defines in the generated header file so there are no conflicts.
The /usr/bin/BuildStrings command accepts the following arguments:
-header Generate a header file. If not provided, default is resource file format. Note that the file extension is not provided automati-
cally; your output file name must have the appropriate .h or .r extension.
-define variable
Defines variable for use in #ifdef or #ifndef conditionals. No value may be assigned to variable. This argument may be repeated
for any number of variables.
-id ResID
The resource ID for the STR# resource. There is no support for setting the resource name.
-attributes attribute
Resource attributes for the STR# resource definition (such as locked, preload, etc.) These are provided after the resource name in
the resource definition. This argument may be repeated for any number of attributes. It is ignored if generating a header.
-type filekind
Customizes three preprocessor variables (MinValidFoo, MaxValidFoo, FooRsrcID) #defined in a generated header file. Note that if
this argument is not provided, the default is the literal string "(null)", which will cause compile errors in the header file.
-in path
The input file, a set of newline-separated pairs of newline-separated strings. The first string of the pair is ignored for the
resource file (but is provided in a comment) and is used as the preprocessor symbol in the header file. The second string of the
pair is used as the resource string in the resource file and is ignored in the header file (but is provided in a comment), and must
be enclosed in double-quotes in your source file.
-out path
The output file. Note that you should provide the appropriate file extension; it is not provided automatically according to the
-header flag.
SEE ALSO Rez(1), DeRez(1)Mac OS X April 12, 2004 Mac OS X