pg.ddx.io  pgsql-sql@postgresql.org mailing list archive  
help / color / mirror / Atom feed
SQL script
3+ messages / 3 participants
[nested] [flat]

* SQL script
@ 2004-04-15 08:22 vickr1z@operamail.com
  2004-04-15 09:12 ` Re: SQL script Richard Huxton <dev@archonet.com>
  2004-04-19 20:17 ` Re: [SQL] SQL script scott.marlowe <scott.marlowe@ihs.com>
  0 siblings, 2 replies; 3+ messages in thread

From: vickr1z@operamail.com @ 2004-04-15 08:22 UTC (permalink / raw)
  To: pgsql-general@postgresql.org; pgsql-sql

good day toall..
imm running postgreSQL on linux.
my main goal is to create a script that will dump a data from our server too  my  local PC. the content of the script would be execute sql command in one shot:
1. dump data
2. update and insert some rows to selected table.

how can i accommplish this task and also how can i run this script? is there any one ccan help me. any idea will appreciate very much.

thanks.

-- 
_____________________________________________________________
Web-based SMS services available at http://www.operamail.com.
From your mailbox to local or overseas cell phones.

Powered by Outblaze



^ permalink  raw  reply  [nested|flat] 3+ messages in thread

* Re: SQL script
  2004-04-15 08:22 SQL script vickr1z@operamail.com
@ 2004-04-15 09:12 ` Richard Huxton <dev@archonet.com>
  1 sibling, 0 replies; 3+ messages in thread

From: Richard Huxton @ 2004-04-15 09:12 UTC (permalink / raw)
  To: vickr1z@operamail.com; pgsql-general@postgresql.org; pgsql-sql

On Thursday 15 April 2004 09:22, vickr1z@operamail.com wrote:
> good day toall..
> imm running postgreSQL on linux.
> my main goal is to create a script that will dump a data from our server
> too  my  local PC. the content of the script would be execute sql command
> in one shot: 1. dump data
> 2. update and insert some rows to selected table.
>
> how can i accommplish this task and also how can i run this script? is
> there any one ccan help me. any idea will appreciate very much.

How are you connecting from client <=> server?
Do you just want a pg_dump style dump, a specific table/query?
Do you need to provide values for this update/insert, or is it fixed (updating 
timestamps sort of thing).

-- 
  Richard Huxton
  Archonet Ltd



^ permalink  raw  reply  [nested|flat] 3+ messages in thread

* Re: [SQL] SQL script
  2004-04-15 08:22 SQL script vickr1z@operamail.com
@ 2004-04-19 20:17 ` scott.marlowe <scott.marlowe@ihs.com>
  1 sibling, 0 replies; 3+ messages in thread

From: scott.marlowe @ 2004-04-19 20:17 UTC (permalink / raw)
  To: vickr1z@operamail.com; +Cc: pgsql-general@postgresql.org; pgsql-sql

On Thu, 15 Apr 2004 vickr1z@operamail.com wrote:

> good day toall..
> imm running postgreSQL on linux.
> my main goal is to create a script that will dump a data from our server too  my  local PC. the content of the script would be execute sql command in one shot:
> 1. dump data
> 2. update and insert some rows to selected table.
> 
> how can i accommplish this task and also how can i run this script? is there any one ccan help me. any idea will appreciate very much.

Just FYI, this might get better response on the admin mailing list...

So, what is your local PC running?  Linux, BSD, Solaris, Windows?  If NOT 
windows, then just install a copy of postgresql on it real quick to get 
access to the pg_dump utilities et. al. and use that to remotely dump the 
data out of the server onto your local machine.

Are you updating / inserting back into the big server, or locally?  either 
way, the easiest way I've found to do it is to use a scripting language 
I'm familiar with (perl, PHP, python, tcl, etc...) and massage the data in 
whatever ways you need to and then insert it into the database with that 
scripting languages pg interface package.  Other ways of doing it would be 
to get it into a SQL dump format and use psql to insert it.




^ permalink  raw  reply  [nested|flat] 3+ messages in thread


end of thread, other threads:[~2004-04-19 20:17 UTC | newest]

Thread overview: 3+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2004-04-15 08:22 SQL script vickr1z@operamail.com
2004-04-15 09:12 ` Richard Huxton <dev@archonet.com>
2004-04-19 20:17 ` scott.marlowe <scott.marlowe@ihs.com>

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox