Yes, there are. Open the ODBC Data Source Administrator utility in
Windows XP (it's under Administrative Tools in the Control Panel). The
very first tab shows the list of user-defined DSN's. Click the Add
button. That will take you to a new menu where you need to select a
driver. Highlight the driver of interest and click the Finish button.
After that, you're in business. The driver will open a form for you to
fill in your connection pass and user id this once, and it will
associate them forever with this data source you just set up. After
that you just need to reference the data source in Stata, and should
not be prompted for a password again. That's what I use in the code
snippet I cc'd you earlier (didn't make it onto the Statalist because
I had the gmail rich formatting turned on by mistake).
Gabi
On Dec 13, 2007 8:54 AM, Tam Phan <[email protected]> wrote:
> All,
>
> My password and Userid for odbc SQL connectivity is different from my
> windows user's login. I have registered this through Window's ODBC
> data source administrator, however, SQL server is still asking me to
> input userid and password whenever I query the database or any part of
> the database. I can't seem to get the password burned in. I believe
> the way previous emails refer to is to use windows NT authentication
> using the network login ID. However, are there ways to handle such
> automation if your windows login ID is different from SQL server id
> and password?
>
> Tam
>
>
> On Dec 13, 2007 2:55 AM, Richard Ohrvall <[email protected]> wrote:
> > Dear all,
> >
> > I think what Ovalho meant was that when you register odbc connection,
> > through eg. Windows' ODBC data source administrator, you can define id
> > and password.
> >
> > But if you don't want to do that, you can always define the user and
> > password directly in your Stata code, see -help odbc-. You do not need
> > to fill in pop up windows every time you load a table.
> >
> > HTH
> > Richard
> >
> >
> > On 12/13/07, Raphael Fraser <[email protected]> wrote:
> > > Orvalho,
> > >
> > > I don't understand your comment. Would you care to elaborate?
> > >
> > > Raphael
> > >
> > > On Dec 11, 2007 1:48 PM, Orvalho Joaquim Augusto <[email protected]> wrote:
> > > > When you register a odbc connection you can define those parameters.
> > > >
> > > > Then you do not have to insert that in Stata.
> > > >
> > > > Caveman
> > > >
> > > >
> > > >
> > > >
> > > > On Tue, 2007-12-11 at 13:33 -0500, Tam Phan wrote:
> > > > > Hi all:
> > > > >
> > > > > Recently I've been using Stata's odbc command. However, I found that
> > > > > entering the password and user ids are cumbersome every single time I
> > > > > wish to query/load tables. Is there anyway to load/query/desc the
> > > > > data set without SQL password/user id messsage box to pop up and
> > > > > re-entering those information?
> > > > >
> > > > > Tam
> > > > > *
> > > > > * For searches and help try:
> > > > > * http://www.stata.com/support/faqs/res/findit.html
> > > > > * http://www.stata.com/support/statalist/faq
> > > > > * http://www.ats.ucla.edu/stat/stata/
> > > >
> > > > *
> > > > * For searches and help try:
> > > > * http://www.stata.com/support/faqs/res/findit.html
> > > > * http://www.stata.com/support/statalist/faq
> > > > * http://www.ats.ucla.edu/stat/stata/
> > > >
> > > *
> > > * For searches and help try:
> > > * http://www.stata.com/support/faqs/res/findit.html
> > > * http://www.stata.com/support/statalist/faq
> > > * http://www.ats.ucla.edu/stat/stata/
> > >
> > *
> > * For searches and help try:
> > * http://www.stata.com/support/faqs/res/findit.html
> > * http://www.stata.com/support/statalist/faq
> > * http://www.ats.ucla.edu/stat/stata/
> >
> *
> * For searches and help try:
> * http://www.stata.com/support/faqs/res/findit.html
> * http://www.stata.com/support/statalist/faq
> * http://www.ats.ucla.edu/stat/stata/
>
*
* For searches and help try:
* http://www.stata.com/support/faqs/res/findit.html
* http://www.stata.com/support/statalist/faq
* http://www.ats.ucla.edu/stat/stata/