Sponsored Content
Full Discussion: Trouble with external tables
Top Forums Shell Programming and Scripting Trouble with external tables Post 302561053 by PG3 on Monday 3rd of October 2011 03:14:54 AM
Old 10-03-2011
Trouble with external tables

Hi All,

My flat file lets say has the following contents

HTML Code:
AT & T
CITIZENS MOHAVE CELLULAR
COMMNET
DRR
E1CELLULAR
....
Now, Im trying to select data from a flat file(sitting on unix server) and want to run a simple query as below(running Oracle 10g)

HTML Code:
SELECT MO_IDENTIFER, SERVICE_PROVIDER FROM MVNO_SP WHERE SERVICE_PROVIDER IN (....
FLAT FILE CONTENTS.
);
I only have READ privileges on this db & hence external tables are not option. So, how do I do a look up on this file & then run a select based on the value of the MVNO Operator generated from the above file. In other words, how do I construct a sql statement where in the value of each row is passed to a variable and that variable is used to read data from the db as below


HTML Code:
SELECT MO_IDENTIFER, SERVICE_PROVIDER FROM MVNO_SP WHERE SERVICE_PROVIDER IN (
'AT & T',
'CITIZENS MOHAVE CELLULAR',
'COMMNET'
.....
);
I been staring at various postings on this topic for a while now and so far, not thing has been posed on the lines of what Im talking about here as everyone has chosen the option of external tables where in we specify the directory that it has to be read from, define the file format etc etc..

Please help.

regards,
PGonzalez.
 

9 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

viewing tables

I have completely blanked out on this and I have done it a million times. I need to modify some tables in unix. What is the command for opening/viewing the tables? Thanks so much. :o (2 Replies)
Discussion started by: itldp
2 Replies

2. UNIX for Dummies Questions & Answers

Routing tables

Hey guys, I needed to add a route to my routing table and I got it to work but on reboot it gets removed. Anyone know what file I can add this route to so it stays on the machine after a reboot? (9 Replies)
Discussion started by: kingdbag
9 Replies

3. Shell Programming and Scripting

Converting tables of row data into columns of tables

I am trying to transpose tables listed in the format into format. Any help would be greatly appreciated. Input: test_data_1 1 2 90% 4 3 91% 5 4 90% 6 5 90% 9 6 90% test_data_2 3 5 92% 5 4 92% 7 3 93% 9 2 92% 1 1 92% ... Output:... (7 Replies)
Discussion started by: justthisguy
7 Replies

4. Shell Programming and Scripting

Tables and borders

when i do this: cat HITS i get the following displayed: sport.hits:87.114.172.31 Thu Sep 28 22:45:12 GMT 2006 how do i put this information into a bordered table? so it will output like this: ...........File /... (9 Replies)
Discussion started by: amatuer_lee_3
9 Replies

5. Shell Programming and Scripting

Display tables of 6

I'm new to linux and unix I would like to know how to display tables of 6 line after line Output should be 1*6 = 6 2*6 = 12 3*6 = 18 4*6 = 24 etc I can display line by line but not continuously Any suggestion (3 Replies)
Discussion started by: electricair
3 Replies

6. UNIX for Dummies Questions & Answers

Mysqldump certain tables

Hi, I have to upload part of my database periodically when i make changes to product data etc. However I only want to upload certain tables. We suffer from bandwidth chock here, so i want to write a couple of separate scripts that upload parts of the database that changed. The database is large... (5 Replies)
Discussion started by: timgolding
5 Replies

7. Programming

C++ Dictionaries and tables

I was looking at this code from a programming book: #include <time.h> #include <iostream> #include <string> #include <deque> #include <map> #include <vector> #include <cstdlib> using namespace std; const int NPREF = 2; const char NONWORD = "\n"; // cannot appear as real line: we... (1 Reply)
Discussion started by: totoro125
1 Replies

8. Shell Programming and Scripting

Compare with 2 tables

I have 3 file inputs, file1 20160302|5485368299953|96|510101223440252|USA|5485368299953|6|800|2300|0 20160530|5481379883742|7|510101242850814|USA|5481379883742|5|540|2181|1500 20160513|5481279653404|24|510100412142433|INDIA|5481279653404|3|380|1900|0... (1 Reply)
Discussion started by: radius
1 Replies

9. Programming

How to arhive hive external tables?

Hi Guys, Is there a way to check hive external tables which are created 90 days before and drop those tables along with underlying hdfs data. Can this be achieved in unix script? (10 Replies)
Discussion started by: Master_Mind
10 Replies
HTML::Microformats::Format::hAlarm(3pm) 		User Contributed Perl Documentation		   HTML::Microformats::Format::hAlarm(3pm)

NAME
HTML::Microformats::Format::hAlarm - an hCalendar alarm component SYNOPSIS
use Data::Dumper; use HTML::Microformats::DocumentContext; use HTML::Microformats::Format::hCalendar; my $context = HTML::Microformats::DocumentContext->new($dom, $uri); my @cals = HTML::Microformats::Format::hCalendar->extract_all( $dom->documentElement, $context); foreach my $cal (@cals) { foreach my $ev ($cal->get_vevent) { foreach my $alarm ($ev->get_valarm) { print $alarm->get_description . " "; } } } DESCRIPTION
HTML::Microformats::Format::hAlarm is a helper module for HTML::Microformats::Format::hCalendar. This class is used to represent alarm components within calendars. Generally speaking, you want to use HTML::Microformats::Format::hCalendar instead. HTML::Microformats::Format::hAlarm inherits from HTML::Microformats::Format. See the base class definition for a description of property getter/setter methods, constructors, etc. Additional Method o "to_icalendar" This method exports the data in iCalendar format. It requires RDF::iCalendar to work, and will throw an error at run-time if it's not available. BUGS
Please report any bugs to <http://rt.cpan.org/>. SEE ALSO
HTML::Microformats::Format::hCalendar, HTML::Microformats::Format, HTML::Microformats. AUTHOR
Toby Inkster <tobyink@cpan.org>. COPYRIGHT
Copyright 2008-2011 Toby Inkster This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself. DISCLAIMER OF WARRANTIES
THIS PACKAGE IS PROVIDED "AS IS" AND WITHOUT ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE. perl v5.14.2 2011-12-06 HTML::Microformats::Format::hAlarm(3pm)
All times are GMT -4. The time now is 09:27 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy