scripts and ~/.psqlrc

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hello

I want to write some scripts which could connect to databse and work in background. I want to avoid situation in which i have to manually/interactively give appriopriate password everytime i query database.

How can i do it in most easily way ?

I found that there is ~/.psqlrc file which could be used as configuration file for user. Can i put there databsename, hostname, username and most important: password ?, so i could connect to my database only by typing:
#psql 

Thanx
Michal

---------------------------(end of broadcast)---------------------------
TIP 1: if posting/reading through Usenet, please send an appropriate
       subscribe-nomail command to majordomo@xxxxxxxxxxxxxx so that your
       message can get through to the mailing list cleanly

[Index of Archives]     [KVM ARM]     [KVM ia64]     [KVM ppc]     [Virtualization Tools]     [Spice Development]     [Libvirt]     [Libvirt Users]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite Questions]     [Linux Kernel]     [Linux SCSI]     [XFree86]

  Powered by Linux