Thread: Time and pg_dump info

  1. #1
    Registered User
    Join Date
    Sep 2005
    Posts
    85

    Time and pg_dump info

    Hello all;

    i have two more for ya!

    First I would like to get the current time and/or date in a string format usin c++.
    This is because I will be creating a filename that will use this information.


    Second If anyone can help with postgreSQL's pg_dump utility:
    I need to know how to pass the password from the command line so that I am not prompted to enter it.

    PS- if someone could give a solution it would be great. I work for a School District and I am trying to make a auto backup utility to SMB sharepoint, but my C++ is a little rusty. I am 90% done though with just these two problems left.


    Thanks

  2. #2
    The Richness... Richie T's Avatar
    Join Date
    Jan 2006
    Location
    Ireland
    Posts
    469
    >>First I would like to get the current time and/or date in a string format usin
    c++

    This might help
    No No's:
    fflush (stdin); gets (); void main ();


    Goodies:
    Example of fgets (); The FAQ, C/C++ Reference


    My Gear:
    OS - Windows XP
    IDE - MS Visual C++ 2008 Express Edition


    ASCII stupid question, get a stupid ANSI

Popular pages Recent additions subscribe to a feed