[SQL] Failed system call was shmget(key=1, size=1155072, 03600).
Hi, when building postgreSQL 8 I get the following error message: DETAIL: Failed system call was shmget(key=1, size=1155072, 03600). HINT: This error usually means that PostgreSQL's request for a shared memory segment exceeded available memory or swap space. To reduce the request size (currently 1155072 bytes), reduce PostgreSQL's shared_buffers parameter (currently 50) and/or its max_connections parameter (currently 10) What is the best way to resolve this? max_connections = 10? Does that figure auto increase as more users request data? regards Andrew ---(end of broadcast)--- TIP 1: subscribe and unsubscribe commands go to [EMAIL PROTECTED]
Re: [SQL] Failed system call was shmget(key=1, size=1155072, 03600).
O Andrew M έγραψε στις Dec 3, 2004 : > Hi, > when building postgreSQL 8 I get the following error message: > > DETAIL: Failed system call was shmget(key=1, size=1155072, 03600). > HINT: This error usually means that PostgreSQL's request for a shared > memory segment exceeded available memory or swap space. To reduce the > request size (currently 1155072 bytes), reduce PostgreSQL's > shared_buffers parameter (currently 50) and/or its max_connections > parameter (currently 10) > > What is the best way to resolve this? max_connections = 10? Does that > figure auto increase as more users request data? > > regards > > Andrew This has been addressed many times, and for many OS's (*Linux, *BSD, etc...). Check the archives. > > > ---(end of broadcast)--- > TIP 1: subscribe and unsubscribe commands go to [EMAIL PROTECTED] > -- -Achilleus ---(end of broadcast)--- TIP 3: if posting/reading through Usenet, please send an appropriate subscribe-nomail command to [EMAIL PROTECTED] so that your message can get through to the mailing list cleanly
Re: [SQL] Failed system call was shmget(key=1, size=1155072, 03600).
On Fri, Dec 03, 2004 at 09:00:53AM +, Andrew M wrote: > DETAIL: Failed system call was shmget(key=1, size=1155072, 03600). > HINT: This error usually means that PostgreSQL's request for a shared > memory segment exceeded available memory or swap space. To reduce the > request size (currently 1155072 bytes), reduce PostgreSQL's > shared_buffers parameter (currently 50) and/or its max_connections > parameter (currently 10) > > What is the best way to resolve this? max_connections = 10? Does that > figure auto increase as more users request data? What are you trying to run this on? It might be that you need to alter your kernel settings. A -- Andrew Sullivan | [EMAIL PROTECTED] In the future this spectacle of the middle classes shocking the avant- garde will probably become the textbook definition of Postmodernism. --Brad Holland ---(end of broadcast)--- TIP 1: subscribe and unsubscribe commands go to [EMAIL PROTECTED]
Re: [SQL] grouping a many to many relation set
On 2-dec-04, at 3:45, Michael Fuhr wrote: On Wed, Dec 01, 2004 at 06:57:54AM +0100, Johan Henselmans wrote: Richard Huxton wrote: I think what's missing here is the explicit statement of which group these belong in. Without a value to sort/group by, there's nothing for your queries to "get a grip on". So - add a "group_id" column to the bank-book and receipt tables. Create a sequence to generate group id's on demand. Thanks for the reply. Adding a group_id column would defeat the whole purpose of the relational model. I do not want to add a grouping beforehand. How is an application going to know which records belong to which groups without a group ID? Or is a group ID acceptable as long as it's not part of the data, but rather generated by the query or function that does the grouping? The grouping should take place according to certain criteria, in this case: group all the records that have at least one of two attributes in common. What about chains like this: bankbookdetid | receiptid ---+--- 100 | 1 100 | 2 101 | 2 101 | 3 102 | 3 102 | 4 Should 1 be grouped with 2, 3, and 4 since 1 has an attribute in common with 2, 2 has an attribute in common with 3, and 3 has an attribute in common with 4? Or doesn't your model permit this situation? -- Michael Fuhr http://www.fuhr.org/~mfuhr/ That is possible indeed. This was the original situation. The trick I use is that from that collection I select the records of which both attribues have a count > 1. But that leads to the situation that some attributes still appear several times in the resulting set. In the above case the resulting set would be 100 | 2 101 | 2 101 | 3 102 | 3 So the group would end up to be all the records that have 2 and 3 or 100, 101 and 102 as part. In the mean time, breaking my head about it, I think I have found a solution: from the resuling set I once again select the record attributes that have a common attribute count > 1 (In your example that would be bankbookdetid = 101, and receiptid 2 and 3). Then we reduce the resulting set to: 101 | 2 101 | 3 Now I can add a group id , which is the attribute of which the count is > 1 (in this case 101), to make sure we don't mix up groupid because bankbookdetid and receiptid might have the same number, so we add 300 to receiptid groups, and 4 to bankbookdetid groups. That is the final set, from where one could go back to the previous set (get all the records that have 101 or 2 and 3 in their respective attributes), that would result in 100 | 2 | 40101 101 | 2 | 40101 101 | 3 | 40101 102 | 3 | 40101 and from there one would go back to ask all the records that have a part in these records, so you could go back to ---+--- 100 | 1 | 40101 100 | 2 | 40101 101 | 2 | 40101 101 | 3 | 40101 102 | 3 | 40101 102 | 4 | 40101 Now it is possible to group. What do you think of the idea? -johan smime.p7s Description: S/MIME cryptographic signature
[SQL] sum query
Hi All, I am trying to join three tables and sum the quantities. The first table contains all of the possible items. The second table contains orders and the third table contains the items on each order. For all items found in tbl_item I need the total quantity on open orders. If an item is not on any open order the quantity should be zero. Can someone please explain the best way to do this? tbl_item id| ... --+... AB12 | ... CD34 | ... EF34 | ... GH12 | ... JK56 | ... tbl_order order | closed |... --++... 1 | false |... 2 | true |... 3 | true |... 4 | false |... 5 | false |... tbl_item order | id| quantity --+---+- 1 | AB12 | 10 1 | CD34 | 5 2 | CD34 | 3 3 | EF34 | 2 3 | GH12 | 20 4 | GH12 | 4 5 | AB12 | 5 id| quantity --+- AB12 | 15 CD34 | 5 EF34 | 0 GH12 | 4 JK56 | 0 Kind Regards, Keith __ 99main Internet Services http://www.99main.com ---(end of broadcast)--- TIP 2: you can get off all lists at once with the unregister command (send "unregister YourEmailAddressHere" to [EMAIL PROTECTED])