473,473 Members | 2,169 Online
Bytes | Software Development & Data Engineering Community
Create Post

Home Posts Topics Members FAQ

Functions not dropped.

I was a little surprised today when I tried to move a production
database on to my test server. The test server already had a copy of
the database so I did

psql -Uadmin template1
drop database admin;
create database admin;

When I tried to reload the production database dump, I got a series of
errors relating to functions. I repeated the exercise but this time did
a \df prior to trying to load the database. In the public schema for the
newly created admin database where all the functions from the old one.
It seems that the drop database doesn't drop all of the functions. Is it
supposed to ? I am using 7.4.2 on FC2.

If it isn't is there a way to clean them all out before the load ?

--
=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
Glen and Rosanne Eustace,
GodZone Internet Services, a division of AGRE Enterprises Ltd.,
P.O. Box 8020, Palmerston North, New Zealand 5301
Ph/Fax: +64 6 357 8168, Mob: +64 27 5 424 015, Web: www.godzone.net.nz

"A Ministry specialising in providing low-cost professional Internet
Services to NZ Christian Churches, Ministries and Organisations"
---------------------------(end of broadcast)---------------------------
TIP 4: Don't 'kill -9' the postmaster

Nov 23 '05 #1
2 2084
On Mon, 2004-11-01 at 21:14, Sim Zacks wrote:
I would check the template1 database to see if you had the functions
defined there as well.
Any functions/structures/data... in template1 will be moved to the new
database. Then when you try to restore the old one it will conflict.


Thanks you.

That is exactly what had happened. I recall on a previous exercise
loading the database but forgetting to created the admin db first and it
loading the whole lot into template1. I remember cleaning out all the
tables etc, I must have forgotten the functions.

Time to re-init the installation.

---------------------------(end of broadcast)---------------------------
TIP 2: you can get off all lists at once with the unregister command
(send "unregister YourEmailAddressHere" to ma*******@postgresql.org)

Nov 23 '05 #2
On Mon, 2004-11-01 at 21:14, Sim Zacks wrote:
I would check the template1 database to see if you had the functions
defined there as well.
Any functions/structures/data... in template1 will be moved to the new
database. Then when you try to restore the old one it will conflict.


Thanks you.

That is exactly what had happened. I recall on a previous exercise
loading the database but forgetting to created the admin db first and it
loading the whole lot into template1. I remember cleaning out all the
tables etc, I must have forgotten the functions.

Time to re-init the installation.

---------------------------(end of broadcast)---------------------------
TIP 2: you can get off all lists at once with the unregister command
(send "unregister YourEmailAddressHere" to ma*******@postgresql.org)

Nov 23 '05 #3

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

Similar topics

99
by: David MacQuigg | last post by:
I'm not getting any feedback on the most important benefit in my proposed "Ideas for Python 3" thread - the unification of methods and functions. Perhaps it was buried among too many other less...
76
by: Nick Coghlan | last post by:
GvR has commented that he want to get rid of the lambda keyword for Python 3.0. Getting rid of lambda seems like a worthy goal, but I'd prefer to see it dropped in favour of a different syntax,...
4
by: Ufit | last post by:
What is the difference between those two. Is there gonna be some difference in app execution for static functions? What difference does it make? UF
1
by: Stephen Quinney | last post by:
I really cannot tell if this is a bug or I am just doing something stupid. I create a table called wibble: CREATE TABLE wibble (a integer, b integer); I insert some data: INSERT INTO...
5
by: Sarloc | last post by:
I'm a user of a brazilian programming forum and I've been reading a discussion that never seems to end on how ctype.h's functions should be used. One of the guys keeps saying that values passed to...
0
by: Glen Eustace | last post by:
I was a little surprised today when I tried to move a production database on to my test server. The test server already had a copy of the database so I did psql -Uadmin template1 drop database...
9
by: TheOne | last post by:
Would anyone please point me to a list of reentrant C library functions? I want to know which C library functions are safe to use inside a signal handler across all platforms. Does GNU C library...
110
by: Gregory Pietsch | last post by:
I'm writing a portable implementation of the C standard library for http://www.clc-wiki.net and I was wondering if someone could check the functions in math.h for sanity/portability/whatever. I'm...
5
by: gponto18 | last post by:
I have a very frustrating and confusing problem here; I have a SQL query that functions perfectly well in Access however when I code it in VB.NET it does not yield the desired results;here is the...
23
by: deepakvsoni | last post by:
Why does C++ restrict definition of functions with in functions? int f1() { int f2() { ..... } } //This is not supported. Thanks in advance to anybody who replies..
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
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...
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,...
1
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...
0
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...
0
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated ...
0
muto222
php
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

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.