We just started using SQL Server. I'm new on the SQL side of things. We have SQL setup in a test environment with users connecting and performing job related functions. An in house programmer has developed software for our users which connects to the SQL Server
I'm looking for information pertaining to events that have teken place within SQL. Does SQL give you details on updates and changes made to specific tables. I'm looking for some way of looking up item numbers and the user that entered the data. We have noticed that some of the users may be entering in wrong data within certain tables. And would like to educate them on what they are doing wrong.
I need to know what certain users are logging and entering into our SQL Server.
What are the most detailed logs that SQL Server provides that has information on what the users are doing has far an entering in data.
I would like to determine the configuration for a given database in Microsoft SQL Server 7.0/2000.
If you examine the properties of databases using SQL Server Enterprise Manager, you can see that certain options exist for a database. For example: - ANSI NULL Default - Recursive triggers - Auto Update statistics - Torn page detection - Auto close - Auto shrink - Auto create statistics - Use quoted identifiers
Can this information be obtain via a stored procedure?
What about information regarding the SQL server configuration itself? If I use SQL Server Enterprise Manager, I can get properties for the server. For example: - "Dynamcially configure SQL server memory" vs "Use a fixed memory size"
Hi there, I was wondering if there is a detailed view control (that can be linked to grid view control) in ordinary C# applications as we have in ASP.NET applications? Please if anyone has information regarding that let me know.
I'm a newbe in SQL Server and I have to build "Detailed Technical Design" Document regarding the SQL Server . If anybody knows something or has an example / structure about this document please send me a replay.....
The best I can get out of my detail log is this which is no help. How do I find out what really happened. My windows app log is no help either
Date 5/24/2006 9:51:41 PM Log Job History (DTS_xx)
Step ID 1 Server xx Job Name DTS_xx Step Name DTS_xx Duration 00:00:01 Sql Severity 0 Sql Message ID 0 Operator Emailed Operator Net sent Operator Paged Retries Attempted 0
Message Executed as user: xxadministrator. The package execution failed. The step failed.
I have a master package with 5 Execute Package Task for sub_packages. How to get the detailed logging information as I see in the debug model in the local file system?
I would like to know how to set the grouping lines or the detailed line to get the function like in Excel: group plan Example:
+ Group line GL1 Detailed Line 1 Detailed Line 2
When the grouping function is active, you see the Group line GL1 only. By clicking on the + icone, you will see all the detailed lines (like in Excel document).
Is it possible to combine a detailed query with its related count and sum without using any #temp tables at all?
ex. select customerID, customerName, (select count(orderID) from tblOrder where orderDate > '01/01/2003' and orderStatus = 'active') as countActive, (select count(orderID) from tblOrder where orderDate > '01/01/2003' and orderStatus = 'inactive') as countInActive from rfCustomers
something like that? I was heard SQL2k has some new feature like this, or a UDF may be required? Currently, I have to use #temp table to get it.
I am using the XML Task to validate an XML file against the XSD schema. Everything works fine, but about detailed errors in the case of the failed validation?
1) I specified €śOperationsResult€? Destination property to save the task execution outcome into a file. 2) Also, I turned on all possible events for logging.
Unfortunately, neither option produces a detailed validation error message. Option 1 saves one single word €śtrue€? or €śfalse€? to a file. Logging produces the following message: Task failed to validate "A validation error occurred when validating the instance document.".
As end result, it is impossible to pinpoint the problem with the xml file and, consequently, fix the issue.
The expected behavior should be a detailed error message like the following (produced by StylusStudio): file:///c:/temp/fafa/feed_bad.xml:12824,52: Datatype error: Type:InvalidDatatypeFacetException, Message:Value '244212' must be less than or equal to MaxInclusive '4'.
It shows a precise location of the error in the XML file plus the specific XSD rule which failed.
Any idea what could be done to get the detailed error message for the XML Task Validation?
Hello, I have a code for creating view in T-SQL. I want to ask you guys, i want to make this result set should grouped by DepoAdi column and StokKodu (this is an alias sure you can get it from code). Did i make it on group by line? My second problem is i want to add 2 columns to this query. This 2 column will calculate some values with SUM function and - operator. At CRM.Depolar.DepoBilgileri table i have a column named Miktar (this one stores int type datas) and i have a column named islemturu(this one stores 1 or 0). I want to calculate Miktar values which rows has islemturu column 0 and subtract them from which rows has islemturu column 1 value and this computing action must be based on Grouped columns.
We have (running SQL 2012 Std) and have enabled trace flag 1204 and 1222 for capturing deadlock through extended events. I have enabled deadlock notification through email .But it only send deadlock event occurred notification from the sql server error log . I was wondering if its possible to email the deadlock details they get generated in extended events via DB mail.
I had a problem with mirroring that I only was able to resolve when I attempted to replicate instead. Replication gave me an error message that expained the problem; mirroring simply failed.
Is there any place where mirroring logs the details of what it is doing & why it is failing?
BTW, the problem was that the server name was changed after SQL was installed. Although i knew this, the forums indicated taht SQL 2005 automatically picks up the new name after it is restarted. This apparently is not true...
I have some troubles with IBM WebSphere Application Server using MS SQL Server 2005 JDBC Driver. I always get the error e.g. java.lang.SecurityException: class "com.microsoft.sqlserver.jdbc.SQLServerDatabaseMetaData"'s signer information does not match signer information of other classes in the same package
I found this Feedback but it seems to be closed.
A temporary solution for me was to delete the meta-inf directory of the JAR-File, but that can't be the solution.
Running this code on my PC via VS 2005 .Net version 2.0.50727 on the server (shown in IIS) Code is in ASP.NET 2.0 and is a VB.NET Console application SSIS 2005
Problem & Info:
I am bringing in an Excel file. I need to first strip out any non-detail rows such as the breaks you see with totals and what not. I should in the end have only detail rows left before I start moving them into my SQL Table. I'm not sure how to first strip this information out in SSIS specfically how down to the right component and how to actually code the component to do this based on my Excel file here: http://www.webfound.net/excelfile.xls
Then, I assume I just use a Flat File Source coponent or something to actually take the columns in the Excel and split into an OLE DB Datasource to shove each column into a corresponding column in my SQL Server Table. I have used a Flat File Source in the past to do so with a comma delimited txt file but never tried with an Excel.
Desired Help:
How to perform
1) stripping out all undesired rows 2) importing each column into sql table
I have a job that runs each night that deletes all records from a table that are older than two weeks old. Is there some way I can view how many records were deleted from the table each night. Is it written to a log somewhere? Thanks in advance!
Hi all, This is my first thread here. I got an information about SET NO_BROWSETABLE ON/OFF in your forum.. The replier told that this is an undocumented option. My question is how you guys find information on such undocumented things....
I am trying to get job information and have a query set up. However, I would also like to get the owner information. However, the job only stores the sid of the owner. Does anybody know how I could change this query to get the owner name instead of sid? Don't want to use the sp_help_job command.
SELECT @@SERVERNAME AS Server, msdb.dbo.sysjobs.job_id, msdb.dbo.sysjobs.name, msdb.dbo.sysjobs.enabled AS Job_Enabled, msdb.dbo.sysjobs.description, msdb.dbo.sysjobs.notify_level_eventlog, msdb.dbo.sysjobs.notify_level_email, msdb.dbo.sysjobs.notify_level_netsend, msdb.dbo.sysjobs.notify_level_page, msdb.dbo.sysjobs.notify_email_operator_id, msdb.dbo.sysjobs.date_created, msdb.dbo.syscategories.name AS Category_Name, msdb.dbo.sysjobschedules.next_run_date, msdb.dbo.sysjobschedules.next_run_time, msdb.dbo.sysjobservers.last_run_outcome, msdb.dbo.sysjobservers.last_outcome_message, msdb.dbo.sysjobservers.last_run_date, msdb.dbo.sysjobservers.last_run_time, msdb.dbo.sysjobservers.last_run_duration, msdb.dbo.sysoperators.name AS Notify_Operator, msdb.dbo.sysoperators.email_address, msdb.dbo.sysjobs.date_modified, GETDATE() AS Package_run_date FROM msdb.dbo.sysjobs INNER JOIN msdb.dbo.syscategories ON msdb.dbo.sysjobs.category_id = msdb.dbo.syscategories.category_id LEFT OUTER JOIN msdb.dbo.sysoperators ON msdb.dbo.sysjobs.notify_email_operator_id = msdb.dbo.sysoperators.id LEFT OUTER JOIN msdb.dbo.sysjobservers ON msdb.dbo.sysjobs.job_id = msdb.dbo.sysjobservers.job_id LEFT OUTER JOIN msdb.dbo.sysjobschedules ON msdb.dbo.sysjobschedules.job_id = msdb.dbo.sysjobs.job_id
I'm looking for books or information on command line configuration of settings for things like activating Remote Connections under the Service Area Configuration and setting a port for that connection.
What books would be good to get or where can I download papers on this?
Hi!This is a very simple question and I'm sure you guys will help me a lot.I'm using Visual Basic 2005 for programming. I have one table on my MS SQL 2005 database that has an int column with a counter that needs to be incremented when a user registers.So when reading the value I use a simple SQL query like this: SELECT counter FROM companies WHERE company=0 then I store the value in a local int variable and then I increment it. Then I update the incremented value. UPDATE companies ... I need every single customer to have an individual value. My question is how can I prevent an error, data corruption or whatever if two or more users want to register at the same time? I've been reading about lock update but I'm not sure how to implement it on Visual Basic 2005 and I don't want to store scripts on SQL Server. I'll appreciate your comments and help on this situation.
Hi, I have a problem here in my SQL Server Database. I want to find which trigger is working backend affecting my table input. Since the original author of this trigger was somebody else, I am not able to find the trigger information A simple line of syntax would be great. Thanks in advance sandeep
I am doing an audit of user information in our database and was wondering if there is a way for me to see the last time a user logged into the database. I am using a SQL Server 7.0 box. Any Information would be greatly appreciated. Thanks!
Hi, In my database one user is aliased like a guest. When i run sp_helpuser on the particular database it is giving following result.
username login name database -------- ----------- -------- aaaa NULL XYZ
NOrmally we fill see like this for GUEST User. Now i want to drop this user 'aaaa' only. IF i use sp_dropuser 'null' i think guest user will also drop from XYZ database. So can anyone pls suggest me how to drop this user. I have to add a same user with full permissions. i know in 65 we have sysalternates table gives all alias information. Is there any table gives the same information in sql7. Pls suggest me regarding this.
I administering SQL server and one of or Db (size ~7 Gb) have a table with size 396 MB and 25 indexes created on this one. We working with this DB using Siebel Call center. I have met a very strange situation: when I tried to get some data (using Siebel) my request take ~5 min. I run Profiler and catched this T-SQL statement which Siebel send to SQL server. After that, I run this T-SQL query using Query Analyser and found that Query Optimiser used wrong index. (clustered index) and try to compare every 470436 rows from the tables. This is the statement. @P1, @P2, and @P3 just variable which siebel transfer to SQL server.
SELECT ........ FROM dbo.S_EVT_ACT T1 LEFT OUTER JOIN dbo.S_CONTACT T2 ON T1.TARGET_PER_ID = T2.ROW_ID WHERE ((T1.APPT_REPT_FLG != @P1 OR T1.APPT_REPT_FLG IS NULL) AND (T1.TEMPLATE_FLG != @P2 OR T1.TEMPLATE_FLG IS NULL)) AND (T1.SRA_DEFECT_ID = @P3)
But I found the very strange situation - when I manualy put the value '1-FRK' instead of @P3 - Query Optimizer used RIGHT index and I had a very good performance.
And addition when I tried to run the first Query on the same table but with the only 1000 rows the Query Optimiser choose right index.
Wat's on, wat happend with My Query Optimizer? Wy his decision so different from time to time?
Thank's a lot for any information about how to make Optimiser obedient.
I need to write an auditing trigger that will capture time of an insert and user that is making the insert. The time part i think i can use getdate(), but how can I find out which user is making the insert? Any help appreciated.
Is there any way to use Transact SQL to get the detailed information on a process like you get when you use the GUI interface under the Enterprise manager for server activity.
Is there a way to view the triggers on a table using query analyzer?
I have a developer that wants to see this information without having to right click every table in the database and viewing the triggers through enterprise manager.