Showing posts with label analyzer. Show all posts
Showing posts with label analyzer. Show all posts

Monday, March 26, 2012

Refresh selection in Query Analyzer?

I add a new table and I want to see it in my list, I can go to EM and refresh there but it appears I have to close QA in order to see the new table. Is there a refresh option in QA to see my new object?

thx,

Kat

Never Mind, I found it, use F5.

Kat

Tuesday, March 20, 2012

Referencing another Database in a query

I'm in query analyzer and I have 2 databases on this same server that I want
to reference in a query. How do I go about doing that? In other words, I
want to create an insert query which takes records from one database and
inserts them into a table in another database.
Thanks,
BrianAssuming that you have appropriate rights in both databases, use three
part naming:
INSERT INTO db1.owner.tablename (Column)
SELECT COLUMN
FROM db2.owner.tablename
HTH,
Stu|||Thanks - I thought I tried that, but I didn't include the 'owner'
"Stu" <stuart.ainsworth@.gmail.com> wrote in message
news:1145403151.928575.228920@.i39g2000cwa.googlegroups.com...
> Assuming that you have appropriate rights in both databases, use three
> part naming:
> INSERT INTO db1.owner.tablename (Column)
> SELECT COLUMN
> FROM db2.owner.tablename
> HTH,
> Stu
>|||Do you have access to both databases?
In SQL each object has a four part identifier which enables cross-database
and cross-server access, provided that the user privileges also allow it.
More information under "Using Identifiers as Object Names" in Books Online.
ML
http://milambda.blogspot.com/|||Here:
http://msdn2.microsoft.com/en-us/library/ms187879.aspx
ML
http://milambda.blogspot.com/