I just checked the manual and it says nothing about being able to use the SQL
copy to access network files.
But you have an option that almost works for you. I am sure others here will
have some suggestions, but if I were in your place, I'd gather more information
about where bottleneck
I don't know about partial indexing, but in a similar situation to what you
describe, I have resorted to special tables designed specifically to hold one
day's worth of data and to support our daily processing. I'd put the daily
data into specific tables, with all the requisite indeces, and the
Here are just a few observations.
What you have described is a classic taxonomy problem. The simplest approach
is to create a table to contain the basic attributes of the obtjects in the
database. Using your example, such attributes may be anatomical (two eyes, two
ears, four limbs, one
Sorry for top posting - but this is an annoying of this web interface to email.
:-(
Isn't what you're doing here a misuse of the idea of a transaction. I don't
claim to be an expert in this, but I thought the idea of a transaction was that
you bundle a group of statements together that m
--- Marcelo de Moraes Serpa <[EMAIL PROTECTED]>
wrote:
> Hello list,
> [snip]
>
> * Each http request gets an instance of a session_id
> ? Or is it
> per-connection ?
It depends. There is no necessary correlation between
a session as defined within a web application and a
session as defined i
--- Stefan Schwarzer <[EMAIL PROTECTED]>
wrote:
> Hi there,
>
> how can I avoid results like this: 9.50184e+06
>
> Instead it should return the "real" value, as
> 950184.
>
But 9.50184e+06 IS the real value! That is about nine
and a half million, not nine hundred and fifty
thousand, BTW. I d
--- Andreas Strasser <[EMAIL PROTECTED]>
wrote:
> Hello,
>
> i'm currently designing an application that will
> retrieve economic data
> (mainly time series)from different sources and
> distribute it to clients.
> It is supposed to manage around 20.000 different
> series with differing
> numb
--- Michael Glaesemann <[EMAIL PROTECTED]> wrote:
>
> On Oct 4, 2007, at 9:30 , Ted Byers wrote:
>
> > I do not know if PostgreSQL, or any other RDBMS,
> > includes the ability to call on software such as
> "R"
>
> See PL/R:
>
> http://w
--- Greg Smith <[EMAIL PROTECTED]> wrote:
> On Fri, 2 Nov 2007, Kevin Hunter wrote:
>
> > I don't have "ammo" to defend (or agree?) with my
> friend when he says
> > that "Postgres requires a DBA and MySQL doesn't so
> that's why they
> > choose the latter."
>
> [snip]
>
> To step back for a
As a prelude to where I really want to go, please
consider the following SELECT statement.
SELECT close_price FROM stockprices A
WHERE price_date =
(SELECT MAX(price_date) FROM stockprices B
WHERE A.stock_id = B.stock_id AND A.stock_id =
id);
stockprices has a primary key comprised
--- Gregory Stark <[EMAIL PROTECTED]> wrote:
> "Ted Byers" <[EMAIL PROTECTED]> writes:
>
> > As a prelude to where I really want to go, please
> > consider the following SELECT statement.
> >
> > SELECT close_price FROM stockprices A
>
--- Tom Lane <[EMAIL PROTECTED]> wrote:
> Ted Byers <[EMAIL PROTECTED]> writes:
> > OK, it is challenging to present it in plain text,
> but
> > here is the HTML exported by MySQL Query Browser.
>
> Why are you asking this list for help with a MySQL
> perf
--- Scott Marlowe <[EMAIL PROTECTED]> wrote:
> On Nov 9, 2007 11:47 AM, Ted Byers
> <[EMAIL PROTECTED]> wrote:
> >
> > --- Tom Lane <[EMAIL PROTECTED]> wrote:
> >
> > > Ted Byers <[EMAIL PROTECTED]> writes:
> [snip]
> Which is
Please consider the following statement (it becomes
obvious if you remember the important thing about the
table is that it has columns for each of stock_id,
price_date, and price).
(SELECT * FROM stockprices WHERE stock_id = 1 ORDER BY
price_date DESC LIMIT 1)
UNION
(SELECT * FROM (SELECT * FROM s
--- Shane Ambler <[EMAIL PROTECTED]> wrote:
> Ted Byers wrote:
> > Please consider the following statement (it
> becomes
> > obvious if you remember the important thing about
> the
> > table is that it has columns for each of stock_id,
> > price_da
Thanks Shane,
It works reasonably well. It gets the right answer,
but I guess my data set is much larger than your test.
Please consider the appended data.
The first two SQL statements are directly comparable.
My Left join is marginally simpler, as shown by
EXPLAIN, and runs to completion in a
--- Richard Huxton <[EMAIL PROTECTED]> wrote:
> Ivan Sergio Borgonovo wrote:
> > On Tue, 04 Dec 2007 08:14:56 +
> > Richard Huxton <[EMAIL PROTECTED]> wrote:
> >
> >> Unless it's an obvious decision (millions of
> small identical
> >> queries vs. occasional large complex ones) then
> you'll ha
IS there such a thing? I can be the first to consider
this.
What I am aiming for is a solution with a couple
coupled tables, one of which represents state through
time and the other represents transactions or deltas
on the state. With one field (a floating point
number) in the state table (or sh
--- Ted Byers <[EMAIL PROTECTED]> wrote:
> IS there such a thing? I can be the first to
> consider
> this.
>
OOPS. The mind is faster than the fingers. That
should have been "I can NOT be the first to consider
this.
Ted
-
--- Erik Jones <[EMAIL PROTECTED]> wrote:
>
> On Dec 6, 2007, at 2:36 PM, Ted Byers wrote:
>
> [snip]
> What you want to do here for handling the update v.
> insert is called
> an "UPSERT". Basically, what you do is run the
> update as if the row
Is there a way to tell pg_dump to just dump the SQL
statements required to create the tables, sequences,
indeces, keys, &c.? I DON'T need to restore or
recreate things like users, or most other kinds of DB
objects. Just routine DDL statements. Looking
through a dump file for a small database, it
Thanks Uwe
This is a great start. It reduces the dump from 2 MB
down to 167K, but out of 6833 lines of SQL, 5744
relate to the public schema in the DB, and I didn't
touch that. It has over a dozen types, 419 functions,
&c., that were put there by postgresql the moment I
created the database. I'
--- Tom Lane <[EMAIL PROTECTED]> wrote:
> Ted Byers <[EMAIL PROTECTED]> writes:
> > Is there a way to tell pg_dump to just dump the
> SQL
> > statements required to create the tables,
> sequences,
> > indeces, keys, &c.?
>
> pg_dump -s
--- Tom Lane <[EMAIL PROTECTED]> wrote:
> Ted Byers <[EMAIL PROTECTED]> writes:
> > It seems the public schema is
> > automagically created by Postgres every time I
> create
> > a new database on a given server, and it has over
> a
> > dozen typ
--- Richard Huxton <[EMAIL PROTECTED]> wrote:
> Tino Wildenhain wrote:
> > Hi Ted,
> >
> > Ted Byers wrote:
> >> Thanks Uwe
> >>
> >> This is a great start. It reduces the dump from
> 2 MB
> >> down to 167K, but out of 6833 li
OK, Now I am a bit confused. The manual doesn't say
what to do if you don't see template1 or template0 on
the server, or even whether or not you should be able
to see them when using a tool like pgAdmin. But it
does say:
"The postgres database is also created when a database
cluster is initializ
Thanks Richard.
--- Richard Huxton <[EMAIL PROTECTED]> wrote:
> Ted Byers wrote:
> > Amyway, when I look at the server using pgadmin, I
> > don't see either template0 or template1. I see
> only
> > template_postgis. Should I be able to see
> template0
&g
Thanks All. I learned plenty this morning.
--- Douglas McNaught <[EMAIL PROTECTED]> wrote:
> On 12/10/07, Ted Byers <[EMAIL PROTECTED]>
> wrote:
>
> > OK. A worry. How is template_postgis
> constructed?
> > Is it just a handy reference to template1? Or
&
Thanks all. I tried the appended code in a trigger
function, but postgresql won't take it.
It complains that assets.quantity is not a scalar.
However, the WHERE clause in that select statement
guarantees that at most only one record will be
returned. An open position on a given kind of asset
is
--- Vivek Khera <[EMAIL PROTECTED]> wrote:
>
> On Dec 10, 2007, at 5:04 PM, Colin Wetherbee wrote:
>
> > For what it's worth, the real algorithm would be
> as follows. I
> > hadn't had enough coffee yet, and I forgot the
> UPDATE bit.
> >
> > IF
> > (a query matching your old data returns r
Thanks Erik
>
> In a stored procedure you'd just execute the UPDATE
> and then check
> the FOUND variable to see if it found a row to
> update:
>
> UPDATE table_name SET foo='bar' WHERE id=5;
>
> IF NOT FOUND THEN
> INSERT INTO table_name (id, foo) VALUES (5, 'bar');
> END IF;
>
To be c
--- Colin Wetherbee <[EMAIL PROTECTED]> wrote:
> Sam Mason wrote:
> > On Sun, Dec 16, 2007 at 06:31:56PM -0500, Colin
> Wetherbee wrote:
> >> If I write one Perl sub for each operation on the
> table (e.g. one that
> >> gets the username and password hash, another that
> gets the last name and
--- Sam Mason <[EMAIL PROTECTED]> wrote:
> On Mon, Dec 17, 2007 at 01:29:10PM -0500, Ted Byers
> wrote:
> > I routinely keep my SQL code distinct from my
> Perl,
> > java or C++ code. When a client program needs to
> do
> > something with the database, then e
--- rihad <[EMAIL PROTECTED]> wrote:
> Dec 18 15:49:41 myhost postgres[29832]: [35-1]
> ERROR: 23505: duplicate
> key value violates unique constraint "foo_key"
> Dec 18 15:49:41 myhost postgres[29832]: [35-4]
> INSERT INTO foo
> Dec 18 15:49:41 myhost postgres[29832]: [35-5]
> (a,b,c)
> Dec 1
--- Bill Moran <[EMAIL PROTECTED]> wrote:
> In response to dvanatta <[EMAIL PROTECTED]>:
>
> >
> > What's up with 3 of the 7 being from Pennsylvania?
> What's the connection?
>
> Well, as everyone knows, Pennsylvania is a haven for
> brilliant
> people. In fact, simply living in Pennsylvania
--- Webb Sprague <[EMAIL PROTECTED]> wrote:
> > ...linear algebra ...
> > >>> ... matrices and vectors .
> > >> ...Especially if some GIST or similar index
> could efficiently search
> > >> for vectors "close" to other vectors...
> > >
I see a potential problem here, in terms of how one
define
--- Martijn van Oosterhout <[EMAIL PROTECTED]> wrote:
> 'transform_null_equals' won't help you at all here
> since it only help
> in the very specific case of comparing with a
> constant. The easiest is
> to think of NULL as meaning 'unknown'. Clearly you
> can't compare that
> usefully with anythi
--- Ian Sillitoe <[EMAIL PROTECTED]> wrote:
> I completely take your points - so maybe I should be
> asking for advice on
> database design instead.
>
> We are annotating nodes on a hierarchical structure
> where NULL implied an
I don't mean to be rude, but yuck. Why provide a
record for data
--- Bob Pawley <[EMAIL PROTECTED]> wrote:
> I'm getting a little frustrated with this problem.
>
> Can anyone tell me what is wrong with the following
> code.
>
> I have tested the portions separately and they all
> work.
>
> When I try it as a whole I get the message "control
> reached end of
> Microsoft
> sql server 2005
> cannot be shared on multiple systems i,e in a
> network environment when
> it is installed in one system it cannot be accessed
> one other
> systems.
>
Nonsense!
Where did you get this stuff?
I have even played with MS SQL Server 2005 Express,
and it is not cri
Is the original application ASP or SP.NET? It makes a difference,
particularly if it was developed to take advantage of ASP.NET 2. It might
conceivably be ASP.NET 3, but since that is brand new I can't see anyone
paying to replace an ASP.NET 3 application that was just created. If it is
ASP.
The question I'd ask before offering a solution is, "Does the order of the
id data matter, or is it a question of having all the results for a given id
together before proceeding to the next id?" The answer to this will
determine whether or not adding either a group by clause or an order by
cl
Hi Ted,
Hi Thorsten,
Am Donnerstag, 25. Januar 2007 19:53 schrieb Ted Byers:
The question I'd ask before offering a solution is, "Does the order of
the
id data matter, or is it a question of having all the results for a given
id together before proceeding to the next id?"
- Original Message -
From: Michael Schmidt
To: Jan Mura ; pgsql-general@postgresql.org
Sent: Thursday, February 08, 2007 12:54 PM
Subject: Re: [GENERAL] SQL textbook
Many books are available for download. Joe Celko is a well respected
author and just about anything with his name on i
- Original Message -
From: "Merlin Moncure" <[EMAIL PROTECTED]>
the open standard to convert data from one database to another,
unfortunately, is SQL. SQL is incomplete, illogical, and obscure, so
here we are.
The same can be said about any programming language, can it not?
Even la
Would it not be simpler to just create two trigger functions, one that acts on
insert operations and a second that acts on update operations? A 30 second
glance at the Postgresql documentation showed me that it is possible to have
more than one row level trigger for a given table, which implies
Maybe his real goal "all the backups readily available to be read by
my program (opening the backup read only)" is to have a historical
record of what certain records looked like in the past.
There are other ways of doing that, though.
If your speculation is right, perhaps the OP ought to expl
- Original Message -
From: "Ron Johnson" <[EMAIL PROTECTED]>
To:
Sent: Wednesday, February 14, 2007 3:46 PM
Subject: Re: [GENERAL] backup database by cloning itself
It seems to me that if you really want a historical record of what
certain tables looked like in the past, it would b
Mark> Similar issues with Mysql. It's faster,
But it doesn't matter *how* fast you get the *wrong* answer. :)
I thought one of the first rules of software engineering was "First make it
right and only then make it fast!"
Granted, most of my experience has more to do with number crunching an
- Original Message -
From: "Joshua D. Drake" <[EMAIL PROTECTED]>
To: "Richard Huxton"
Cc:
Sent: Thursday, March 08, 2007 8:00 AM
Subject: Re: [GENERAL] OT: Canadian Tax Database
Richard Huxton wrote:
http://www.thestar.com/News/article/189175
"For instance, in some cases the fiel
And due at least in part to government (and other institutions operated
by
damned fools) opting for the least expensive provider rather than paying
for
someone who actually knows what they're doing. Just as buying cheap junk
always comes back to get you, hiring incompetent fools that don't kn
- Original Message -
From: "Alan Hodgson" <[EMAIL PROTECTED]>
To:
Sent: Thursday, March 08, 2007 11:32 AM
Subject: Re: [GENERAL] OT: Canadian Tax Database
On Thursday 08 March 2007 08:15, "Ted Byers" <[EMAIL PROTECTED]>
wrote:
They would have satis
> Richard Huxton wrote:
>> http://www.thestar.com/News/article/189175
>>
>> "For instance, in some cases the field for the social insurance number
>> was instead filled in with a birth date."
>>
>> Unbelievable. Sixty years of electronic computing, fifty years use in
>> business and the "professio
- Original Message -
From: "Bill Moran" <[EMAIL PROTECTED]>
To: "Rikard Pavelic" <[EMAIL PROTECTED]>
Cc: "Tom Lane" <[EMAIL PROTECTED]>;
Sent: Thursday, March 08, 2007 3:18 PM
Subject: Re: [GENERAL] security permissions for functions
In response to Rikard Pavelic <[EMAIL PROTECTED]>
Functions are controlled by the same ACL mechanism that tables and
everything
else follows. Thus you have the idea of "user id X may do Y with object
Z"
i.e. "user "barbara" may "execute" function "somefunction()".
But there's no real way to alter those permissions outside of changing the
us
It is not hard to calculate, as you can see... but it would be nice if
"date_trunc('week', date)" could do that directly. Even if it became
"date_trunc('week', date, 4)" or "date_trunc('week', date, 'Wednesday')"
it
would be nice... :-) And that is what I was trying to ask ;-)
Use date_trun
- Original Message -
From: "Omar Eljumaily" <[EMAIL PROTECTED]>
To: "Ted Byers" <[EMAIL PROTECTED]>
Cc:
Sent: Friday, March 09, 2007 5:00 PM
Subject: Re: [GENERAL] Setting week starting day
Ted, my reason for asking the question that I believe prec
- Original Message -
From: "omar" <[EMAIL PROTECTED]>
To:
Sent: Friday, March 09, 2007 10:40 PM
Subject: Re: [GENERAL] OT: Canadian Tax Database
Tom, I promise this isn't a political statement, even though it's on the
same thread.
I'm curious what people think about the following st
- Original Message -
From: "Randall Smith" <[EMAIL PROTECTED]>
I'll give the pghackers forum a visit and since I'm already on the subject
here, I'll make a direct comparison of the situation. Microsoft's Internet
Explorer web browser is known to have poor support for the CSS standard
Naz
First, there is nothing you can do about the computational load except make
your code as efficient as possible. Get it right and then make it fast.
But there is only so much you can do. If a "calculation" requires an
integer sum and an integer difference, you inevitably have two integer
I am not sure I see why it would be good to do this using SQL, but I do know
that I have used a number of Perl packages for this sort of thing. When I have
done this in the past, I'd do the date and time calculations in Perl and feed
the result to whatever RDBMS I happen to be using (PostgreSQL
and Python? How would you compare them
to the other options (such as C++, Java, Perl, &c.)?
Cheers,
Ted
Rich Shepard <[EMAIL PROTECTED]> wrote:
On Mon, 30 Apr 2007, Ted Byers wrote:
> I am not sure I see why it would be good to do this using SQL, but I do
> know
ed procedure, placing the index in a variable that has scope local to the
procedure, and use that variable in the second insert?
Thanks,
Ted
R.E. (Ted) Byers, Ph.D., Ed.D.R & D Decision
Support Softwarehttp://www.randddecisionsupportsolutions.com/
Hi Jaime,
Thanks.
I'd suggest the manual be edited by an educator, since it is a little dense
for someone coming to it for the first time. Once I read your reply to me,
and reread the manual, I understood. But on first reading, it is a little
too dense and short on examples.
Regarding ser
ks to all who helped me on this matter.
Cheers,
Ted
R.E. (Ted) Byers, Ph.D., Ed.D.R & D Decision
Support Softwarehttp://www.randddecisionsupportsolutions.com/
ing
software to all relevant people/sites.
If you faced this problem, what would you do, and why?
Cheers,
Ted
R.E. (Ted) Byers, Ph.D., Ed.D.
R & D Decision Support Software
http://www.randddecisionsupportsolutions.com/
---(end of broadcast)-
Did you find a fix for it?
- Original Message -
From:
Jonel
Rienton
To: 'Ted Byers' ; pgsql-general@postgresql.org
Sent: Wednesday, December 28, 2005 1:24
PM
Subject: RE: [GENERAL] Final stored
procedure question, for now anyway
it's
uggestions?
- Original Message -
From:
Jonel
Rienton
To: 'Ted Byers' ; pgsql-general@postgresql.org
Sent: Wednesday, December 28, 2005 4:16
PM
Subject: Re: [GENERAL] Final stored
procedure question, for now anyway
yup, just use lowercase all the
ti
- Original Message -
From: "Frank L. Parks" <[EMAIL PROTECTED]>
To:
Sent: Wednesday, December 28, 2005 7:27 PM
Subject: [Bulk] Re: [GENERAL] Final stored procedure question, for now
anyway
Do you refresh you database after you add the function? It will not show
up until after you
y servlet that processes user data. After all, I have bitten
the bullet to learn about stored procedures and functions precisely because of
my studies of ways to make distributed applications secure.
Thanks,
Ted
R.E. (Ted) Byers, Ph.D., Ed.D.R & D Decision
Support Softwarehttp://www.randddecisionsupportsolutions.com/
Nico,
I do not believe there is anyone who can tell you the "best way to go" as
that is determined by far more than DB access.
That said, I am inclined to agree with John. I would expand on that to say
that if Delphi is the only language you know, then it is the best option for
getting prod
tions I am designing. Any insights you,
or others, may have on these questions would be greatly appreciated.
Cheers,
Ted
R.E. (Ted) Byers, Ph.D., Ed.D.
R & D Decision Support Solutions
http://www.randddecisionsupportsolutions.com/
---(end of broadcast)-
Bob,
If you're interested in a free java tool, you might want
to look at NetBeans (now version 5). It is one of the best I have seen,
and I have used a wide variety of such tools in a number of different
programming languages. Understand, though, that you have a wide
variety of options,
uld be appreciated.
Thanks,
Ted
R.E. (Ted) Byers, Ph.D., Ed.D.R & D Decision
Support Solutionshttp://www.randddecisionsupportsolutions.com/
I am developing a small web application. Currently, our web server is
sitting outside our firewall (running its own firewall), and the
application
being developed would let users do things like place orders.
My question is...what and where is the database for this?
What do you mean when you
May I ask a question about this?
I will be working on an older database in which the original developer
stored XML documents as a single variable length text field. To process it,
it has to be retrieved in full and parsed. But the structure of it is
simple in that it has an element for each
On Thursday 30 March 2006 03:03, Aaron Glenn wrote:
Anyone care to share the great books, articles, manifestos, notes,
leaflets, etc on data modelling they've come across? Ideally I'd like
to find a great college level book on data models, but I haven't come
across one that even slightly holds "d
- Original Message -
From: "Merlin Moncure" <[EMAIL PROTECTED]>
To: "Janning Vygen" <[EMAIL PROTECTED]>
Cc:
Sent: Wednesday, April 12, 2006 12:31 PM
Subject: Re: [GENERAL] Hardware related question: 3ware 9500S
[snip]
> - I want to know if 3ware 9500 S is recommended or if its one o
- Original Message -
From: "Scott Marlowe" <[EMAIL PROTECTED]>
To: "Ted Byers" <[EMAIL PROTECTED]>
Cc: "Merlin Moncure" <[EMAIL PROTECTED]>; "Janning Vygen" <[EMAIL PROTECTED]>;
"pgsql general"
Sent: Wednesda
79 matches
Mail list logo