home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #26 / NN_1992_26.iso / spool / comp / database / sybase / 272 < prev    next >
Encoding:
Text File  |  1992-11-09  |  1.3 KB  |  32 lines

  1. Newsgroups: comp.databases.sybase
  2. Path: sparky!uunet!zaphod.mps.ohio-state.edu!magnus.acs.ohio-state.edu!lbertoli
  3. From: lbertoli@magnus.acs.ohio-state.edu (Lawrence E Bertolini)
  4. Subject: Re: Hiding a password while dumping
  5. Message-ID: <1992Nov9.132919.28336@magnus.acs.ohio-state.edu>
  6. Sender: news@magnus.acs.ohio-state.edu
  7. Nntp-Posting-Host: bottom.magnus.acs.ohio-state.edu
  8. Organization: The Ohio State University
  9. References: <1688@anagld.analytics.com>
  10. Date: Mon, 9 Nov 1992 13:29:19 GMT
  11. Lines: 19
  12.  
  13. To supply a password to isql, without coding it on the command line, try:
  14.  
  15. isql -Usa -Sservername << !
  16. `cat .x`
  17. `cat $1`
  18. !
  19.  
  20. where ".x" contains your password, and $1 is the name of the file
  21. containing your dump database command.
  22.  
  23. The "<< !" is called a "here document", and redirects to stdin everything
  24. until the "!" is found in column 1.  The two cat commands are enclosed in
  25. grave's, so that the output of the cat commands (i.e. the contents of the
  26. files .x and $1) are part of the "here document".
  27. -- 
  28. +-----------------------+-------------------------------------------------+
  29. | Larry Bertolini       | "Patriotism is your conviction that this country|
  30. | Ohio State University | is superior to all other countries because      |
  31. | University Systems    | you were born in it." - George Bernard Shaw     |
  32.