| Author |
Topic |
|
boreddy
Posting Yak Master
172 Posts |
Posted - 2008-08-07 : 02:35:58
|
| I have Script now i connected to DB1 databasefrom this database i need to execute that script to DB2 database(another database)how it possible please help me |
|
|
visakh16
Very Important crosS Applying yaK Herder
52326 Posts |
Posted - 2008-08-07 : 02:40:27
|
| are they in same server? if yes you can execute. you just need to specify qualifier DB2. for all objects. |
 |
|
|
webfred
Master Smack Fu Yak Hacker
8781 Posts |
Posted - 2008-08-07 : 02:41:24
|
| select column from database.schema.tablenameWebfred |
 |
|
|
webfred
Master Smack Fu Yak Hacker
8781 Posts |
Posted - 2008-08-07 : 02:42:13
|
again - too late |
 |
|
|
VGuyz
Posting Yak Master
121 Posts |
Posted - 2008-08-07 : 02:46:16
|
| if the database is in same server select col1,col2 from database_name..table_nameif the database is in some other server use linked server concept |
 |
|
|
webfred
Master Smack Fu Yak Hacker
8781 Posts |
Posted - 2008-08-07 : 02:50:18
|
| select parrot from zoo.avian.cage |
 |
|
|
visakh16
Very Important crosS Applying yaK Herder
52326 Posts |
Posted - 2008-08-07 : 02:53:23
|
quote: Originally posted by webfred again - too late 
|
 |
|
|
boreddy
Posting Yak Master
172 Posts |
Posted - 2008-08-07 : 03:00:02
|
| if it is tbale i can apply ur suggestionhere my script is very big and i used many system tables,systemviews and join and temp tableit not possible |
 |
|
|
visakh16
Very Important crosS Applying yaK Herder
52326 Posts |
Posted - 2008-08-07 : 03:34:15
|
quote: Originally posted by boreddy if it is tbale i can apply ur suggestionhere my script is very big and i used many system tables,systemviews and join and temp tableit not possible
Why are trying to run it from other db in first place? |
 |
|
|
boreddy
Posting Yak Master
172 Posts |
Posted - 2008-08-07 : 03:52:23
|
| Here requirement is like thisend user will connect to server and they will give database name,by useing this database i shoul have to get the tables,column,constraints,column datatypein given formatehere i wrote the code to get all above requirementswhere i run this this cript i am getting that database related informationi am not able to get the user given database information |
 |
|
|
sodeep
Master Smack Fu Yak Hacker
7174 Posts |
Posted - 2008-08-07 : 13:25:02
|
| Show us what you have tried. |
 |
|
|
|