Path: csiph.com!v102.xanadu-bbs.net!xanadu-bbs.net!feeder.erje.net!eu.feeder.erje.net!newsfeed.xs4all.nl!newsfeed2.news.xs4all.nl!xs4all!newsgate.cistron.nl!newsgate.news.xs4all.nl!post.news.xs4all.nl!not-for-mail Return-Path: X-Original-To: python-list@python.org Delivered-To: python-list@mail.python.org X-Spam-Status: OK 0.029 X-Spam-Evidence: '*H*': 0.94; '*S*': 0.00; 'python,': 0.02; 'subject:two': 0.07; 'logic': 0.09; 'rows': 0.09; 'all,': 0.19; 'print': 0.22; 'code': 0.31; 'file': 0.32; 'another': 0.32; 'subject:from': 0.34; 'but': 0.35; 'received:google.com': 0.35; 'subject:data': 0.36; 'charset:us-ascii': 0.36; 'similar': 0.36; 'message-id:@gmail.com': 0.38; 'to:addr:python-list': 0.38; 'to:addr:python.org': 0.39; 'expression': 0.60; 'new': 0.61; 'header:Message-Id:1': 0.63 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=subject:from:content-type:message-id:date:to :content-transfer-encoding:mime-version; bh=nY7EZTR6x2hf2IIb42mNY0Ee6kj4RLeI8ZqLCgKbkBE=; b=bJOryK1Y8f56EnwFBc6/YvqafRX3ZiV4cRuInp/HqoNdWbXFYx4lbbYtGDBoE+TEn2 SCJiorap4TNQwzy+6jr9Ja3TCK6rvvCq7p46jm9LhOVW8eycYWnG5OUlQ+idimsqXccI SQQOYiWQFGDl6XzkG5Rsd9YzNmA9dGJnU7xNo9lNMW2XFuZyXU/ifYIG2UgbIV2sS7Pk R4LmPXSWn6zAnEKc5uTnIa7PdcgDDnMa8JUk3xHJzBdFH5EzPb/sLHBiXcU3ZAht9vms vX3bPuuz4L6Mzw53239xt77A0sx9DcnNB1LzZjC8y4iBBSaVddb9rVaUSGQUUITboyXZ lztA== X-Received: by 10.68.252.106 with SMTP id zr10mr433058pbc.63.1382060937214; Thu, 17 Oct 2013 18:48:57 -0700 (PDT) Subject: finding data from two different files. From: "torque.india@gmail.com" Content-Type: text/plain; charset=us-ascii X-Mailer: iPad Mail (11A501) Date: Fri, 18 Oct 2013 07:18:49 +0530 To: python mail list Content-Transfer-Encoding: quoted-printable Mime-Version: 1.0 (1.0) X-Mailman-Approved-At: Fri, 18 Oct 2013 04:11:50 +0200 X-BeenThere: python-list@python.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: General discussion list for the Python programming language List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Newsgroups: comp.lang.python Message-ID: Lines: 26 NNTP-Posting-Host: 2001:888:2000:d::a6 X-Trace: 1382062311 news.xs4all.nl 15981 [2001:888:2000:d::a6]:34235 X-Complaints-To: abuse@xs4all.nl Xref: csiph.com comp.lang.python:57015 Hi all, I am new to python, just was looking for logic to understand to write code i= n the below scenario. I am having a file (filea) with multiple columns, and another file(fileb) wi= th again multiple columns, but say i want to use column2 of fileb as a searc= h expression to search for similar value in column3 of filea. and print it w= ith value of rows of filea. filea: a 1 ab b 2 bc d 3 de e 4 ef . . . fileb z ab 24 y bc 85 x ef 123 w de 33=20 Regards../ omps=