That works great thank you. I have ran a few test's on smaller files, and its fine,
I have 2 further queries that extend this. First, the lookup file contains 1.87 million rows, and the CSV file to check it against, contains 400,000 rows (there are around 40 csv files to chec).
Running it takes a very long time, so I'm wondering if that might change the command at all, or if it just needs to run overnight.
The second query, is can I use the awk command above, but instead of searching in a csv, can i search a directory? If we take the example above:
Can I instead add a find command? So read the first line of the csv and get:
Then search
Recursively and find the filename that contains it?
Thank you so much for your help so far, very kind!
Hi All,
I've two .csv files as below
file1.csv
abc, tdf, 223, tpx
jgsd, tex, 342, rpy
a, jdjdsd, 423, djfkld
Where as file2.csv is the new version of file1.csv with some added fields in the end of each line and some additional lines.
lfj, eru, 98, jkldj, 39, jdkj9
abc, tdf, 223, tpx,... (3 Replies)
EDIT: My problems have been solved thanks to the help of bartus11 and pravin27
This code is just to help me learn. It serves no purpose other than that.
Here's a sample csv that I'm working with -
#listofpeeps.csv
Jackie Chan,1954,M
Chuck Norris,1930,M
Bruce Lee,1940,M
This code is... (13 Replies)
Hi!
I'm just new to shell scripting n simple tasks looks so tough in initial stage. i need to write a script which will read a property file, property file will be containing count of the csv files, and in a folder(same folder) there will be respective csv files.
like Property file
data1=100... (3 Replies)
Hi All,
I want to remove the rows from File1.csv by comparing a column/field in the File2.csv. If both columns matches then I want that row to be deleted from File1 using shell script(awk). Here is an example on what I need.
File1.csv:
RAJAK,ACTIVE,1
VIJAY,ACTIVE,2
TAHA,ACTIVE,3... (6 Replies)
Hi All,
I want to remove the rows from File1.csv by comparing the columns/fields in the File2.csv. I only need the records whose first column is same and the second column is different for the same record in both files.Here is an example on what I need.
File1.csv:
RAJAK|ACTIVE|1... (2 Replies)
Hello,
I have about 10 csv files which range from csv1 - csv10.
Each csv file has same type/set of tabs and we have around 5-6 tabs for each of the csv file which have slightly different content(data).
A sample of CSV1 is shown below:
Joins: Data related to Joins, it can be any number of... (2 Replies)
Hi All,
My requirement is to write a shell script to compare two large csv files.
I've created sample files for explaining my problem
i.e., a.csv and b.csv
contents of files:
-----------------
a.csv
------
Type,Memory (Kb),Location HD,Size (Mb),Serial #
XT,640,D402,0,MG0010... (2 Replies)
I have two csv files and im trying to compare them. e.g.
SAMPLE DATA:
file one:
ZipCode Name
20878 Washington
10023 Missouri
20304 Maryland
file two:
ID Name City ZipCode
11654 ... (11 Replies)
Discussion started by: dan139
11 Replies
LEARN ABOUT OSX
dbix::class::storage::dbi::uniqueidentifier
DBIx::Class::Storage::DBI::UniqueIdentifier(3) User Contributed Perl Documentation DBIx::Class::Storage::DBI::UniqueIdentifier(3)NAME
DBIx::Class::Storage::DBI::UniqueIdentifier - Storage component for RDBMSes supporting GUID types
DESCRIPTION
This is a storage component for databases that support GUID types such as "uniqueidentifier", "uniqueidentifierstr" or "guid".
GUIDs are generated automatically for PK columns with a supported data_type, as well as non-PK with auto_nextval set.
METHODS
new_guid
The composing class must set "new_guid" to the method used to generate a new GUID. It can also set it to "undef", in which case the user is
required to set it, or a runtime error will be thrown. It can be:
string
In which case it is used as the name of database function to create a new GUID,
coderef
In which case the coderef should return a string GUID, using Data::GUID, or whatever GUID generation method you prefer. It is passed
the $self DBIx::Class::Storage reference as a parameter.
For example:
$schema->storage->new_guid(sub { Data::GUID->new->as_string });
AUTHOR
See "AUTHOR" in DBIx::Class and "CONTRIBUTORS" in DBIx::Class.
LICENSE
You may distribute this code under the same terms as Perl itself.
perl v5.16.2 2012-08-16 DBIx::Class::Storage::DBI::UniqueIdentifier(3)