473,786 Members | 2,795 Online
Bytes | Software Development & Data Engineering Community
+ 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 2098
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 YourEmailAddres sHere" to ma*******@postg resql.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 YourEmailAddres sHere" to ma*******@postg resql.org)

Nov 23 '05 #3

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

Similar topics

99
5925
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 important changes, so in this thread I would like to focus on that issue alone. I have edited the Proposed Syntax example below to take out the changes unecessary to this discussion. I left in the change of "instance variable" syntax (...
76
3799
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, rather than completely losing the ability to have anonymous functions. Anyway, I'm looking for feedback on a def-based syntax that came up in a recent c.l.p discussion:...
4
1676
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
1492
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 wibble VALUES (1,1);
5
1616
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 any of the functions should be cast to unsigned char and the other guy keeps saying that there is no need for that. Both of them seem to know what they are talking about and I am confused. So I thought to myself: hey, maybe I should ask other...
0
982
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 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
9
8301
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 make few other functions reentrant on Linux platform? I have searched a lot on the web for it but without any success. Man page of signal(2) has listed system calls (POSIX 1003.1-2003 list) which are safe(reentrant) but thats not sufficient for...
110
8620
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 almost halfway through writing the over 200 functions needed to implement C99's version of math.h, and I would like to have some feedback and/or expert advice on my implementations. Sincerely, Gregory Pietsch
5
2163
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 code: Dim oledbConnection As New OleDb.OleDbConnection("Provider=Microsoft.Jet.OLEDB.4.0;Data Source=" & InstallLocation & "SDE.mdb;User Id=admin;Password=;") oledbConnection.Open() Dim oledbCommand As New...
23
1840
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
9650
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, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
9497
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 effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
10363
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
1
10110
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 Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
1
7515
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 presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
5398
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
5534
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
4067
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 we have to send another system
2
3670
muto222
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.