Re: [PERFORM] Volunteer to build a configuration tool

2007-06-18 Thread James Neethling



This is my idea:

A JavaScript HTML page that would have some basic questions at the top:

1) How much memory do you have?

2) How many connections will be made to the database?

3) What operating system do you use?

4) Etc…

Next the person would press a button, “generate”, found below the 
questions. The JavaScript HTML page would then generate content for 
two Iframes at the bottom on the page. One Iframe would contain the 
contents of the postgresql.conf file. The postgresql.conf settings 
would be tailored more to the individuals needs than the standard 
default file. The second Iframe would contain the default settings one 
should consider using with their operating system.


My web team would be very happy to develop this for the PostgreSQL 
project. It would have saved us a lot of time by having a 
configuration tool in the beginning. I am willing to make this a very 
high priority for my team.




Hi Lance,

I agree that having a page that can assist in generating a base 
configuration file is an excellent way to start off with a good 
configuration that can assist a system administrator in getting half way 
to a good configuration. We've recently gone through a process of 
configuring a machine and it is a time consuming task of testing and 
benchmarking various configuration details.


My thoughts:
Using the browser is a great idea as a universal platform. I can 
foreseen a problem in that some users won't have GUI access to the 
machine that they are setting up. I don't have much direct experience in 
this field, but I suspect that a great number of installations happen 
'headless'? This can easily be circumvented by hosting the configuration 
builder on a public internet site, possibly postgresql.org?


Also, Javascript isn't the easiest language to use to get all the 
decisions that need to be made for various configuration options. Would 
it not be a better idea to host a configuration builder centrally, 
possible on postgresql.org and have the documentation reference it, 
including the docs that come packaged with postgresql (README, INSTALL 
documentation?). This would mean that you wouldn't be able to package 
the configuration builder, but you would be able to implement more 
application logic and more complex decision making in a hosted 
application. Of course, I have no idea of the skills that your team 
already have :)




To add ideas: perhaps a more advanced tool would be able to add comment 
indicating a suggested range for the particular setting. For example, 
with 2Gb of RAM, it chooses a workmem of, say, 768Mb, with a comment 
indicating a suggested range of 512Mb - 1024Mb.



Thanks for taking the time to put this together and for offering the 
services of your team.


Kind regards,
James









begin:vcard
fn:James  Neethling
n:Neethling;James 
org:Silver Sphere Business Solutions
adr:Centurion Business Park A2;;25633 Democracy Way;Prosperity Park;Milnerton;Cape Town;7441
email;internet:[EMAIL PROTECTED]
title:Managing Member
tel;work:27 21 552 7108
tel;fax:27 21 552 7106
tel;cell:27 83 399 2799
x-mozilla-html:FALSE
url:http://www.silversphere.co.za
version:2.1
end:vcard


---(end of broadcast)---
TIP 5: don't forget to increase your free space map settings


Re: [PERFORM] column totals

2006-05-26 Thread James Neethling



James Neethling wrote:

Hi There,

I've got a situation where I need to pull profit information by 
product category, as well as the totals for each branch.


Basically, something like

SELECT branch_id, prod_cat_id, sum(prod_profit) as prod_cat_profit
   FROM () as b1
WHERE x = y
GROUP BY branch, prod_cat_id


Now, I also need the branch total, effectively,
SELECT branch_id, sum(prod_profit) as branch_total
   FROM () as b1
WHERE x = y
GROUP BY branch_id.


Since the actual queries for generating prod_profit are non-trivial, 
how do I combine them to get the following select list?
SELECT branch_id, prod_cat_id, sum(prod_profit) as prod_cat_profit,  
sum(prod_profit) as branch_total


Or is there a more efficient way?

Kind Regards,
James


---(end of broadcast)---
TIP 4: Have you searched our list archives?

   http://archives.postgresql.org
  
begin:vcard
fn:James  Neethling
n:Neethling;James 
org:Silver Sphere Business Solutions
adr:Centurion Business Park A2;;25633 Democracy Way;Prosperity Park;Milnerton;Cape Town;7441
email;internet:[EMAIL PROTECTED]
title:Managing Member
tel;work:27 21 552 7108
tel;fax:27 21 552 7106
tel;cell:27 83 399 2799
x-mozilla-html:FALSE
url:http://www.silversphere.co.za
version:2.1
end:vcard


---(end of broadcast)---
TIP 9: In versions below 8.0, the planner will ignore your desire to
   choose an index scan if your joining column's datatypes do not
   match