473,468 Members | 4,540 Online
Bytes | Software Development & Data Engineering Community
Create Post

Home Posts Topics Members FAQ

Reset oid , starting value=1

Hello,
i have a bug in a php application based on postgres 7.2.2 , which cannot
handle oid's greater than
2147483647 .
So I have to reset the used oids to start from 1 again, so that we have more
time to correct this bug, I tried to delete dropdb, createdb and read back
the data, but the oids are not reseted , they start at the high values.
How can i reset this oid-starting from value ?
Are OIDs used once per postgres-installation (so they are unique over all
databases, seem to be that way) , or are they only counted up in the current
database ?
There must be a global value which sets the last oid, i need to set this to
"1" or to fill up from 1 , so i have no oids >= 2147483647 for the near
future.. how can i do this ? Fixing the mentioned above will take more time.

What i am looking for is a vacuumdb -a --forgetthoseoids ;-) , but I cannot
find infos about that.

bye,
Andre Gellert

---------------------------(end of broadcast)---------------------------
TIP 8: explain analyze is your friend

Nov 12 '05 #1
1 2543
The only way to reset oids is to destroy the entire data directory and
initdb again. In recent versions you can create tables without oids, thus
reducing their usage.

Hope this helps,

On Tue, Dec 09, 2003 at 11:22:15AM +0100, Gellert, Andre wrote:
Hello,
i have a bug in a php application based on postgres 7.2.2 , which cannot
handle oid's greater than
2147483647 .
So I have to reset the used oids to start from 1 again, so that we have more
time to correct this bug, I tried to delete dropdb, createdb and read back
the data, but the oids are not reseted , they start at the high values.
How can i reset this oid-starting from value ?
Are OIDs used once per postgres-installation (so they are unique over all
databases, seem to be that way) , or are they only counted up in the current
database ?
There must be a global value which sets the last oid, i need to set this to
"1" or to fill up from 1 , so i have no oids >= 2147483647 for the near
future.. how can i do this ? Fixing the mentioned above will take more time.

What i am looking for is a vacuumdb -a --forgetthoseoids ;-) , but I cannot
find infos about that.

bye,
Andre Gellert

---------------------------(end of broadcast)---------------------------
TIP 8: explain analyze is your friend
--
Martijn van Oosterhout <kl*****@svana.org> http://svana.org/kleptog/ (... have gone from d-i being barely usable even by its developers
anywhere, to being about 20% done. Sweet. And the last 80% usually takes
20% of the time, too, right?) -- Anthony Towns, debian-devel-announce


-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.0.6 (GNU/Linux)
Comment: For info see http://www.gnupg.org

iD8DBQE/1a9rY5Twig3Ge+YRAkoQAKDXiqiQsIfhyPAk2azm1jLPCEQuyg CePtNV
LeH2LBrWp37Nskr35b6Liek=
=z7bj
-----END PGP SIGNATURE-----

Nov 12 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

9
by: Ken | last post by:
How can I reset the initial form variables that are set with session statements when clicking on a button? I tried this but the function was not called: <?PHP function reset_form($none) {...
2
by: Matt | last post by:
i need to implement a clear button to clear all the fields in the form, but i am thinking i can just use reset button. <input type="reset" name="reset" value="CLEAR"> The first thought is...
4
by: Chris Lane | last post by:
Hi, I have an HTML RESET button and Web Control Button that posts back to the server. Problem is the reset button doesn't work after the postback occurs. Any ideas or suggestions as to why this...
1
by: NancyASAP | last post by:
Thought I'd share this since it took me a long time to get it working. Thanks to a bunch of contributers in Google Groups who shared javascript, etc. The question was: How can I put a reset...
4
by: Lee Chapman | last post by:
Hi, Can anyone tell me why in the code below, the call to ClearChildViewState() has no effect? To paraphrase the code: I'm using view state. I have a textbox and a submit button (and a label...
2
by: Lance | last post by:
I want to be able to reset a complex property in a PropertyGrid. I know that for properties that are ValueTypes you can include System.ComponentModel.DefaultValue in the declaration of the property....
3
by: mark | last post by:
My program has several global arrays declared but not sized: Public Shared A As Double(,), Public Shared B As Double(,), etc. As methods are called the arrays are sized as appropriate for...
2
by: Roger Withnell | last post by:
I need to reset a form to its original value using onclick rather than the Reset button. So, I have: <input type="button" name="reset" id="reset" value="Reset" onclick="form1.reset();"> where...
11
by: newbie | last post by:
i have a form in which a hidden field (initial value as '0', and my javascript set it to '1' when an event is trigged). In the same form, i have a reset field. But I realized that the hidden field...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
1
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.