Sponsored Content
Special Forums UNIX and Linux Applications Single table or split the table Post 302769569 by DGPickett on Tuesday 12th of February 2013 04:12:05 PM
Old 02-12-2013
What is really slick is a RDBMS with partitioned tables, so removing and adding are fast and simple. You can name and recycle the same partitions for the 31 days. If the primary key is time or insert order, you can mix servers in the same partition, but RDBMS guys are hyper this way, so they usually use separate partitions and you get strict time order in each for free. Yes, indexes to suport slow queries are good, if they do not slow insert too much. Definitely one table.

Ever consider near real time flow using remote clients? It often makes the data more useful, and there are not such large processing surges. Batch went out with punched cards.
This User Gave Thanks to DGPickett For This Post:
 

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

Check the record count in table (table in oracle)

I have requirement: 1) Check the record count in table (table in oracle) 2) If records exists generate the file for existing records and wait for some time (Go to sleep mode) and Again check the record count after 10 min.......... (Loop this process if record count >0). 3) Generate touch... (1 Reply)
Discussion started by: kamineni
1 Replies

2. Shell Programming and Scripting

Check the record count in table (table in oracle)

I have requirement: 1) Check the record count in table (table in oracle) 2) If records exists generate the file for existing records and wait for some time then Go to sleep mode and Again check the record count after 10 min.......... (Loop this process if record count >0). 3) Generate touch... (1 Reply)
Discussion started by: kamineni
1 Replies

3. Shell Programming and Scripting

select values from db1 table and insert into table of DB2

Hi I am having three oracle databases running in three different machine. their ip address is different. from one of the DB am able to access both the databases.(means am able to select values and insert values in to tables individually.) I need to fetch some data from DB1 table(say DB1 ip is... (2 Replies)
Discussion started by: aemunathan
2 Replies

4. UNIX and Linux Applications

create table via stored procedure (passing the table name to it)

hi there, I am trying to create a stored procedure that i can pass the table name to and it will create a table with that name. but for some reason it creates with what i have defined as the variable name . In the case of the example below it creates a table called 'tname' for example ... (6 Replies)
Discussion started by: rethink
6 Replies

5. UNIX for Dummies Questions & Answers

Creating a condensed table from a pre-existing table in putty

Hello, I'm working with putty on Windows 7 professional and I'd like to know if there's a way to gather specific lines from a pre-existing table and make a new table with that information. More specifically, I'd like the program to look at a specific column, say column N, and see if any of the... (5 Replies)
Discussion started by: Deedee393
5 Replies

6. Shell Programming and Scripting

Build a table from a list by comparing existing table entries

I am new to this shell scripting.... I have a file which contains list of users. This files get updated when new user comes into the system. I want to create script which will give a table containing unique list of users. When I say unique, it means script should match table while parsing... (3 Replies)
Discussion started by: dchavan1901
3 Replies

7. UNIX and Linux Applications

Help in copying table structure to another table with constraints in Oracle

hi, i need to copy one table with data into another table, right now am using create table table1 as select * from table2 i want the constraints of table1 to be copied to table2 also , can anyone give me some solution to copy the constraints also, now am using oracle 10.2.0.3.0... (1 Reply)
Discussion started by: senkerth
1 Replies

8. Shell Programming and Scripting

awk to convert table-by-row to matrix table

Hello, I need some help to reformat this table-by-row to matrix? infile: site1 A:o,p,q,r,s,t site1 C:y,u site1 T:v,w site1 -:x,z site2 A:p,r,t,v,w,z site2 C:u,y site2 G:q,s site2 -:o,x site3 A:o,q,s,t,u,z site3 C:y site3 T:v,w,x site3 -:p,routfile: SITE o p q r s t v u w x y... (7 Replies)
Discussion started by: yifangt
7 Replies

9. Web Development

Getting Rid of Annoying Bootstrap Table Borders and Wayward Table Lines

Bootstrap is great; but we have had some issues with Bootstrapped <tables> (and legacy <fieldset> elements) showing annoying, wayward lines. I solved that problem today with this simple jQuery in the footer: <script> $(function(){ $('tr, td, fieldset,... (0 Replies)
Discussion started by: Neo
0 Replies

10. UNIX for Beginners Questions & Answers

Read Table in file and split

HELLO I need your help please , i need to read a file that contain a table like : Name | Status ------------------ DB 1 | UP DB 2 | UP DB 3 | DOWN DB 4 | UP DB 5 | UP the objective to read each line and check if DB is UP or Down and give me the name of Down database.... (10 Replies)
Discussion started by: Abdellah
10 Replies
Data::ObjectDriver::Driver::Partition(3pm)		User Contributed Perl Documentation		Data::ObjectDriver::Driver::Partition(3pm)

NAME
Data::ObjectDriver::Driver::Partition - base class for partitioned object drivers SYNOPSIS
package SomeObject; __PACKAGE__->install_properties({ ... primary_key => 'id', driver => Data::ObjectDriver::Driver::Partition->new(get_driver => &find_partition), }); # Say we have a list of 5 arrayrefs of the DBI driver information. my @DBI_INFO; sub find_partition { my ($part_key, $args) = @_; my $id; if (ref $terms && ref $terms eq 'HASH') { # This is a search($terms, $args) call. my $terms = $part_key; $id = $terms->{id} or croak "Can't determine partition from a search() with no id field"; } else { # This is a lookup($id) or some method invoked on an object where we know the ID. my $id = $part_key; } # "ID modulo N" is not a good partitioning strategy, but serves as an example. my $partition = $id % 5; return Data::ObjectDriver::Driver::DBI->new( @{ $DBI_INFO[$partition] } ); } DESCRIPTION
Data::ObjectDriver::Driver::Partition provides the basic structure for partitioning objects into different databases. Using partitions, you can horizontally scale your application by using different database servers to hold sets of data. To partition data, you need a certain criteria to determine which partition data goes in. Partition drivers use a "get_driver" function to find the database driver for the correct partition, given either the arguments to a "search()" or the object's primary key for a "lookup()", "update()", etc where the key is known. SUGGESTED PRACTICES
While you can use any stable, predictable method of selecting the partition for an object, the most flexible way is to keep an unpartitioned table that maps object keys to their partitions. You can then look up the appropriate record in your get_driver method to find the partition. For many applications, you can partition several classes of data based on the ID of the user account that "owns" them. In this case, you would include the user ID as the first part of a complex primary key. Because multiple objects can use the same partitioning scheme, often Data::ObjectDriver::Driver::Partition is subclassed to define the "get_driver" function once and automatically specify it to the Data::ObjectDriver::Driver::Partition constructor. Note these practices are codified into the Data::ObjectDriver::Driver::SimplePartition class. USAGE
"Data::ObjectDriver::Driver::Partition->new(%params)" Creates a new partitioning driver. The required members of %params are: o "get_driver" A reference to a function to be used to retrieve for a given object or set of search terms. Your function is invoked as either: o "get_driver(\%terms, \%args)" Return a driver based on the given "search()" parameters. o "get_driver($id)" Return a driver based on the given object ID. Note that $id may be an arrayref, if the class was defined with a complex primary key. o "pk_generator" A reference to a function that, given a data object, generates a primary key for it. This is the same "pk_generator" given to "Data::ObjectDriver"'s constructor. "$driver->search($class, $terms, $args)" "$driver->lookup($class, $id)" "$driver->lookup_multi($class, @ids)" "$driver->exists($obj)" "$driver->insert($obj)" "$driver->update($obj)" "$driver->remove($obj)" "$driver->fetch_data($what)" Performs the named action, by passing these methods through to the appropriate database driver as determined by $driver's "get_driver" function. DIAGNOSTICS
No errors are created by Data::ObjectDriver::Driver::Partition itself. Errors may come from a specific partitioning subclass or the driver for a particular database. BUGS AND LIMITATIONS
There are no known bugs in this module. SEE ALSO
Data::ObjectDriver::Driver::SimplePartition LICENSE
Data::ObjectDriver is free software; you may redistribute it and/or modify it under the same terms as Perl itself. AUTHOR &; COPYRIGHT Except where otherwise noted, Data::ObjectDriver is Copyright 2005-2006 Six Apart, cpan@sixapart.com. All rights reserved. perl v5.12.4 2011-08-29 Data::ObjectDriver::Driver::Partition(3pm)
All times are GMT -4. The time now is 01:35 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy