Dumping database results and doing checksums


 
Thread Tools Search this Thread
Top Forums Shell Programming and Scripting Dumping database results and doing checksums
# 1  
Old 10-22-2014
Dumping database results and doing checksums

hey I am dumping two database results into two text files and doing checksums on them.

Anyone know how to do this.

I originally was doing line by line comparison and diff but I need something faster for larger gb size files. anyone got tips?
# 2  
Old 10-22-2014
How fast is your disk? How large is your memory? You could run md5sum on it for checksums and see if they match. When operating on a gb file, it's not going to happen in a split second no matter what.
# 3  
Old 10-22-2014
Checksum is generally not used in this fashion. Using checksum to compare files from two different data sources is questionable. A checksum is usually used to insure that a single file or copy of that file is the same or has not been modified. Doing a checksum on linux is as simple as....
Code:
sum <file>

I didn't see the complete message regarding the large file.
These 2 Users Gave Thanks to blackrageous For This Post:
# 4  
Old 10-22-2014
Good point, a checksum does character for character matching, a single irrelevant space would upset it.
# 5  
Old 10-22-2014
That sounds kind of expensive. Standard SQL should be able to tell you something.

Code:
SELECT * FROM ( 
SELECT 'tablea' from_tab, * FROM tablea minus SELECT * FROM tableb@otherdb
union all
SELECT 'tableb' from_tab, * FROM tableb@otherdb minus SELECT * FROM tablea );


Last edited by Corona688; 10-22-2014 at 12:34 PM..
# 6  
Old 10-22-2014
sum seems to be doing the trick. can someone comment on what it does im still researching .

how is it that if i go into a large file and change one letter it picks up that change? what is behind that?
Login or Register to Ask a Question

Previous Thread | Next Thread

9 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

How to store "scp" results in a database table?

Hi, When I use scp to copy a file from other location, I get the output like filename, time taken etc on console. I want to store that into a database table (in oracle). Could someone give me some pointers on how to achieve this? Regards, Sachin Vaidya (1 Reply)
Discussion started by: notthatsachin
1 Replies

2. Programming

Serial file transfer protocol / checksums

Hello ppl, I'm working on a windows program simulating an existing Unix program, the program is a firmware downloader, it sends a binary firmware file through the serial port (rs232) to a Set-Top Box running under unix system too, as i'm a poor unix user and not a unix programmer i choosed the... (10 Replies)
Discussion started by: nidal
10 Replies

3. Shell Programming and Scripting

Can ctag and cscope support recording search results and displaying the history results ?

Hello , When using vim, can ctag and cscope support recording search results and displaying the history results ? Once I jump to one tag, I can use :tnext to jump to next tag, but how can I display the preview search result? (0 Replies)
Discussion started by: 915086731
0 Replies

4. Red Hat

Core Dumping?

How to now if the server is core dumping into the same filesystem? (4 Replies)
Discussion started by: 300zxmuro
4 Replies

5. UNIX for Dummies Questions & Answers

Dumping network packets

Hi, My Solaris Workstation has got 4 NICS, out of which one of them(bge3) is unplugged from the rest of the external network & connected to other interface(bge1). The isolated NIC serves as a simulated Ethernet Interface for my application under development. Now, I'd like to capture RAW... (1 Reply)
Discussion started by: smanu
1 Replies

6. BSD

Checksums in Microsoft FTP Server

hi, I wanted to know from anyone out there a way to perform a checksum command on a Microsoft FTP Server for a file and compare this with the checksum of the file that was transferred from a Unix machine. Thanks, Erick (1 Reply)
Discussion started by: ewhindle
1 Replies

7. BSD

Checksums in Microsoft FTP Server

hi, I wanted to know from anyone out there a way to perform a checksum command on a Microsoft FTP Server for a file and compare this with the checksum of the file that was transferred from a Unix machine. Thanks, Erick (0 Replies)
Discussion started by: ewhindle
0 Replies

8. UNIX for Advanced & Expert Users

Dumping multiple Folders

How would i go about dumping my /home/ directory and my /root directory i currently have..... dump -f /root/backup.dp /home/ /root/ ...but dump only seems to see only my first source directory and not the second (/root in this case) anyone know a way around this..or if it is even... (1 Reply)
Discussion started by: Freakytah
1 Replies

9. UNIX for Dummies Questions & Answers

Dumping files to tape

Can anyone please help.... how can I dump just a single file to tape using the ufsrestore command!!! I'm a newbie to unix and It's driving me mad.. Thanks in advance. (2 Replies)
Discussion started by: Jonathan
2 Replies
Login or Register to Ask a Question