I have an update trigger that works wonderful as long as I am updating the row in Enterprise Manager, but if I update the same column and row using an update statement in Query Analyzer the trigger doesn't fire.
I want a trigger in db aaa to fire when table a_aaa is updated in server a and table b_bbb in db bbb in server b to be populated with data. I know how to write a trigger if fired and the result stays in one server with one db. But I don't know how to do it if between two servers and two db.
a win server 2003 standard Edition sql Server 2000 db:aaa table: a_aaa column:a_aaa_a
b win server 2003 standard Edition sql Server 2000 db:bbb table:b_bbb column: b_bbb_b
It's not working because the symtax is incorrect and because I am not sure how to do it between two servers. If it is not correct, where am I wrong? Where should each line be located?? et cetera...... Can anyone help?
Thanks in advance.
CREATE TRIGGER [enddate_changed_on_alert] ON [dbo].[USER_DATA]
FOR INSERT, UPDATE AS
BEGIN SET NOCOUNT ON;
DECLARE @EndDate as DATE DECLARE @CompCode as VARCHAR(15) DECLARE @PhoneGMSM as VARCHAR(10) DECLARE @PhoneALERT as VARCHAR(10)
SELECT @PhoneALERT=phone1 from AUSSMEDEVIQ1.QDB_Test.USER_DATA; SELECT @PhoneGMSM=PHONE1 from AUSADFORMULA02.QDB_KS.dbo.USER_DATA_DEVIQ;
UPDATE AUSADFORMULA02.QDB_KS.dbo.USER_DATA_DEVIQ SET EXT4 = "111" WHERE AUSSMEDEVIQ1.QDB_Test.USER_DATA.@Phone = AUSADFORMULA02.QDB_KS.dbo.USER_DATA_DEVIQ;
Dear Experts,I'm an Oracle guy, who is being given more SQL Server assignmentslately.I've been looking for things on the web about this, but I can'tanything so far.In Oracle, I you can create a trigger on a table that -only- fires ifcertain fields are updated.create or replace trigger trg_some_triggerBEFORE insertOF some_field1, some_field2on tbl_some_tablefor each row....Is this also possible in SQL Server?What is the syntax please?Thanks a lot!
Need to parsing serverName and databaseName to run a dynamic query to get serverName and databaseName and employee_ID via a accountID parameter. ----------------------------- declare @stringSQL varchar(200) select @stringSQL= 'insert into temp1 select '+@AccountID+' accountID, employee_ID from ' + @serverName +'.dbo.'+@databaseName+'.tblEmployee where inactive=0' print @stringSQL_GetUserName exec (@stringSQL_GetUserName) select * from temp1 ------------------------------ above dynamic query works fine. Howevery, this should be run only under insertion event. When I put it in a proc to run within the insertion trigger or put the whole sql statement within the trigger:
1. when ran at a MSDE server MSDTC on server is unavailable.
2. when ran at a SQL2000 developer testing server with the distributed transaction coordinator on, the insertion a record in the isql/w hang there. Could not even to kill this query, and have to stop and restart the SQL server.
Then I just want to return the dynamic query result without 'insert into temp1 ', the result is still hang... Is there a way to let the insert trigger to run a dyanamic query which linked to around 10 servers?
On one of our machines, all of the SQL Server 2000components except for the main Server component (SQL Servercore) itself were installed (Management tools, etc) a while agoand everything was running fine. Now I go and add/install theServer component and then Service Pack 3a.It seems that Service Manager won't start up (I get an hourglass cursor)and now I find that Enterprise Manager won't run as well. No errormessages appeared and I don't think I saw anything unusual inthe log file.However, I can use Enterprise Manager on a differentmachine and connect to the database (so the databaseitself seems to be running).Any suggestions as to what the problem might be and how tofix it? I like to see if I can repair this without havingto do a reinstall.Thanks.PF
IF someone can assist me. Everytime I load up enterprise manager the service manager turns off. And the enterprise manager can't connect to the local database. But everytime i turn it back on and try to connect again it shuts it off and around and around we go. Help would be appreciated. Thanks.
I installed SQL Server MSDE 2000 but I can't find how to start it. Does this package include an Enterprise Manager or not? I thought that maybe it was a standard XP Pro feature. I had no problem finding it in W2000 Pro.
Has anyone encountered this error: When you are in Enterprise manager and you select a database then the tables tab and then you select a table and go to open table- select all rows, I get an error--An unexpected error happened during this operation-Query Designer encountered a query error! Please let me know if you have seen this. Also, when I access this from one networked computer I get the same error, then when I access it from another I do not!! The servers are interacting with Pivotal. The one that works does not!!
Hi all, I have SQL 7.0 desktop addition installed on my local win NT workstation. I am able to connect to my local server using Quary Analyser but when i am trying to connect using EM, i am not able to connect. I am receiveing the following error message. __________________________________________________ ___________________________ A conncetion could not be established to "servername" - Specified SQL Server not found. ConnectionOpen(CreateFile()). Please verify SQL server is running and check your SQL Server registration properties(by right clicking "servername" node) and try again. __________________________________________________ ___________________________ I have tried as said in the error message and also tried connecting with "sa" but its not working. I can see that the server is running and i am able to connect through QA.
I am fairly new sql dba in a company and I am sure Enterprise Manager is installed on PC's and it shouldn't. Is there a way of finding out other then visiting each workstation. Thanks in advance..
I am considering upsizing my Access 2000 DB to a SQL 7 server. I was told that having SQL 7 Enterprise Manager is highly prefferd but not essential as I can maintain the upsized DB with Access 2000. The only way that I have been able to find JUST enterprise manager seems to be with purchasing the whole SQL 7 program for $1300! Microsoft cannot be that cruel, that you have to buy the whole program just for Enterprise Manager!
My questions are:
Can I download just MS SQL 7 Enterprise Manager anywhere for a reasonable fee or free?
and
if not, can I continue to use Access 2000 to maintain the SQL 7 upsized DB?
I have access to a SQL 7 server via my ISP Hosting account. I know Enterprise manager comes with the server software, but how can I get a copy of JUST Enterprise Manager?
Is it possible to administer both 6.5 and 7.0 databases from the same SQL Enterprise Manager? I have read that you cannot do this because the 7.0 "plug-in" to the MMC wont work with 6.5 databases.
We had database corruption and cannot access the Enterprise Manager. DBCC returned errors 9000 to 9999 which I can't get any suggestions on how to handle from BOL. Any ideas!!!!! Thanks.
Hi, I would like to know if we can present users to access details database information about the databases on a server through Enterprise Manager. If you create a SQL login and do NOT give it access to any database, if someone logons on your server with enterprise manager, even though he does not have access to any database, he will still see the list of all database on your servers plus tons of sensitive information like database owner. Is is possible to limit enterprise manager to only view information about database that the user has access to?
How can I force users of Ent Manager 6.5 to enter a name/password when connecting to a server that has been registered? I dont want to use the sa name and password so that anyone could use my workstation to access our servers.
Does anyone know how to turn off or disable the auto discovery for Enterprise Manager. Apparently our Network group is complaining that Enterprise Manager is generating noise on the network, it is not signifcant in volume but they complain it impacts there ability to detect hacking attempts on our network because it causes some false positives. I generally keep Enterprise Manager running because I will always have some manual job running from it and we have so many servers it takes awhile for them to all load when I first fire it up.
I have SQL server 2000 client machine on my XP desktop which worked fine until yesterday. Yesterday, I tried to set up client access (a tool from IBM to access AS400) unsuccesfully. Since ever, Each time I try to open a table in enterprise manager, I get the following error message "The query cannot be executed because some files are either missing or not registered. Run setup again to make sure the required files are registered". While when I issue a query in analyzer it works fine.
I did that several times without success. Even, I removed the whole SQL 2000 setup, rebooted my machine, ran set up again for client tools which gave the same result. Also, I re-setup MDAC2.6 SP2 but no way.
Which files are corrupted ?and I don't understand after doing all that, setup goes smoothly without indicating any errors, but still when you open a table in enterprise manager, it gives the same error.
Using MS SQL Server 7. When I go into a table in design view and order by date created, it only orders on the day and not the date (Enterprise Manager) e.g.
When we click on the Query Analyzer Shortcut, it will prompt for a user id and password.but when we expand the databases node from EM and clicks on Tools->Query Analyzer Menu, after selecting a database node, the QA does not prompt for the user id and password. Can any one explain this behaviour of QA..
I am using Mixed mode authentication for my db server.
When I view the database properties using Enterprise Manager, some of the databases on the server are reporting that there is zero space available while others have space available. Does anybody know why?
Does anyone know where I can get a copy of Enterprise Manager? I have the trial copy of 2000, but I need to administer data on a SQL 7 server, and I cannot create stored procedures, add users, or create DTS packages in 2000 that will work on SQL 7. Thanks!
Is it possible to add custom columns to the design table interface. For example could I add custom column for some data on want to store under a table column. I am used to vb.net and I am able to add custom properties to a control. Is this type of customization possible for SQL Server. Is it possible to add a custom tab to the tab control where columns are located at the bottom of the designer?
I installed SQL Server Developer Edition on Windows 2003 server for our sales force. I don't want them to have acces to enterprise Manager and Query Analyser.
Hi all, I am not over familiar with SQL, I am a VB Programmer, however I need to achieve the following.
In Enterprise Manager I have 2 tables A and B.
I need to get a column from A and then scan the entire contents of B to see whether the content, the value from the column in A actually exists in B. The get the next value from A and repeat the process.