Answer Questions
Trevor E Hilder Trying to return DISTINCT COLUMN data with varying information
I'm trying to find the best way to return distinct data from a column (Message). The problem is that the messages are not distinct. Ex. Message1 - An unhandled exception occurred type 123456 Message2 - An unhandled exception occurred type 346742 Both of these messages are being returned since they are not unique. Now I was thinking about doing a character length and dropping the message after x number of chars, however, there are other issues like the unique data in the message isn't always in the same location. Any ideas of how to query this would be much appreciated. ...But 10,000 is an exaggeration right You could use patindex to work out where the word 'type' is, and then get the string from there ...Show All
Walter30140 Restting value in id column
hi guys i was wondering if anyone could help me, i have a table with a field called id that did have numbers 1,2,3,4,5,6,7,8 and so on! but after some tinkering i have removed a few value and added more so i now have 1, 4,8,19,20 and so on! i was wondering if i can run a query to update those values and return them to 1,2,3,4,5,6,7,8 and so on i know i shouldnt of been messing! but how on earth do you learn without mistakes!!! Cheers Tupps Is this id column an identity If so, you can't really get back the missed values easily. Check out identity_insert in BOL for a way to fill gaps, but generally you should not use identities values if you care about the values. It is just a method to get a unique value, not a sequenti ...Show All
hazz Database Modification (Insert/Update/Delete) Event Notifications
Hello, I am new to SQL Server and am building a C# application which will use a local SQL Server Express 2005installation. My application will be interacting with a DB Schema with approx 250 tables and the schema is already defined. My application is responsible for monitoring changes to the data in the DB. It must watch for all data changes in the database (Insert/Update/Delete). I am looking for a way to monitor changes to the DB data due to Insert/Update/Delete activity. Is there a simple way in SQL Server for my application to receive events whenever the table content is modified. I have come up with a few ideas myself, for example adding trigger to each table to update an additional Event table that I could look at or even r ...Show All
Babalicious SSMA Migration Tools
hi all I am Facing problem for using this tools (Migrate from Sybase to SQL Server 2005) when i trying to connect to Sybase on Tools EM, this error apper Error Collecting Data . See the Inner Exception for Details please anyone can help in this issue or advice me what can i do thank's Glad about the feedback from you and MS in this case, I'm sure they will enable that build soon to public. I am trying to migrate from ASA to SQL Server too, can you tell me what tool can I use to IMPORT my database or at least the information contained in it to SQL SERVER 5 Thanks in advance. Hosam Abd EL-Wahab wrote: hi all I am Facing problem for using this tools (Migrate from Sybase to SQL Se ...Show All
Metaferia Create device in emulator from Management Studio
Hi, i know i have the chance to access my mobile device (physical or emulator) from Management Studio. I went to Connect Object Explorer, server type Sql Server Mobile but i can’t connect to my emulator and i can’t see any way to connect to a physical device either. How can i do this The only thing i can do is create a sql server mobile database (.sdf). Thanks SP Moving to Sql Server Compact Edition forum where it has got better chance of being answered. -Thanks, Mohit You can do this only if your device (or emulator) is connected through active sync. Object Explorer: Connect-> Database file-> Select 'Browse for more' and then select ...Show All
Dave9999 Monitoring SQL Server activies from an outside environment
Hi, I don't know if this is the right place to post this kind of question (moderators, please move it to the right place if it's not here). I want to know how can I monitor some operations that are executed on a SQL Server database. Operations like: INSERT, DELETE, UPDATE, transactions, and so on (I know that I can do this using triggers, but doing this way I'll have to fill a table with the information from the triggers and stay loading the table data all the time. I want a way to monitor using other resources, in realtime). My idea is to build a program to monitor these activities (C# to be more exactly). How can I do this Thanks Allen, I know some commercial products, but I'm planning a project for my graduation degr ...Show All
RainerJ Attribut Key Not Found Error
I am creating a cube using two tables: Users : UserID PrimaryKey (Dimension) Sources: SourceID Primary Key (Fact & Dimension) When I deployed the cube I was getting the followong errors Warning 1 Errors in the OLAP storage engine: The attribute key cannot be found: Table: dbo_Users, Column: UserID, Value: 1. Warning 2 Errors in the OLAP storage engine: The record was skipped because the attribute key was not found. Attribute: Users of Dimension: Users from Database: WorkFlowMonitor_3 4 5, Cube: Test, Measure Group: Sources, Partition: Sources, Record: 1. Error 3 Errors in the OLAP storage engine: An error occurred while processing the 'Sources' partition of the 'Sources' measure group for the 'Test' cube from the TestMonito ...Show All
Tryin2Bgood Database Tuning Advisor DTA Import Session Results?
Hi, I have ran the Tuning Advisor (DTA) on a .trc file. Recommendations and reports came back. I would like to take my exported session results and import that file into a DTA on a different machine with the SQL Server 2005 developer tools installed. The file is the following Job010704SessionResultsExported.xml I see how to import a session definition. I do not see how to import 'session results.' Any ideas oh how to do that Thanks, AIMDBA DTA does not have such feature. You can file a feature request here. https://connect.microsoft.com/sqlserver ...Show All
osamaT conditional display
To simplify, I have a report with sections A,B, and C. Section A is always displayed. Section B is only displayed when the subject is Male. Section C is only displayed when the subject is Female. I want section B or C to directly follow section A. I have been using the hidden property to do this, but it is hard to maintain the report as I have placed these two sections on top of each other on the Layout tab. Is there a way to make either section B or C directly follow section A without having them overlap in the Layout tab I believe I understand what you are trying to do. You always want to display table A first. If table B has data, table B will show directly under table A. If table B does not have d ...Show All
LeonR OO storage? How to store large graphs and enable efficient graph operations?
Storing large graph in relational form doesn't allow us to perform graph operations such as shortest path quite efficiently. I'm wondering if storing the graph as objects would be better How should I design the schema Thanks! No. You want T-SQL QUERYING (not programming). There is an entire chapter (ch.9) dedicated to graphs, hierachies, etc. in Itzik's book. Highly recommend it. http://www.amazon.com/Inside-Microsoft-SQL-Server-2005/dp/0735623139/ref=pd_sim_b_2/002-5855731-9288849 ie=UTF8&qid=1172821634&sr=8-4 THanks, oj. But ch 9 is Transactions. Is that what you meant No. Chapter 9 is about graphs, trees, hierachies, and recursive queries. Did ...Show All
Mike Strobel How To Delete Rows In SQL
Does the SQL DELETE command actually delete records or just mark them for deletion. And if so, how do you force a physical deletion (code required). Thanks. Dim command As SqlClient.SqlCommand = New SqlClient.SqlCommand( "DELETE FROM Table WHERE Day=" & "Monday", connection) connection.Open() command.ExecuteNonQuery() connection.Close() Yes, the delete command physically deletes data. It's funny how my dB size increased after I ran the Delete command. It's up 29MB, but I'm not sure how many records I deleted and what's the root cause of the increase and what's in that increase. I did do a test preview and it did refle ...Show All
Alexei Moudretsov Identifying a table update / insert / delete
How to find out that a table has changed. For example if a table has 50K rows, and if any update, insert, or delete was made it should be captured without using any trigger. Is it possible to get such information from any of the system table or DMVs Hi akbar Thanks for the info. This means I have to add the columns in every table for which I need to track the changes. Suppose i have existing database & do not have the flexibility to change it, then what should be the option Thanks Umachandar for providing the information. Please don't rely on rowmodctr. The behavior has changed in SQL Server 2005. And you cannot distinguish ...Show All
asiaindian SQL Server vs Windows Application Project maintenance?
I'm a database newbie, trying to decide whether to create an SQL Server or Windows Application project that uses SQL Server 2005 Express. As I understand it, the advantage of an SQL Server project is that the app deploys somehow as part of the database. If that's the case, how would I handle the scenario where the database has been updating at customer site and I need to install just a new release of the software Would I be better of creating a Windows Application project and connecting to the database explicitly Thank you. - Windows Application project == A classic EXE with rich GUI - SQL Server project == a DLL that must hosted by sqlserver, the code you write runs inside sqlserver. NO GUI, only obj ...Show All
Buddy question concerning kpis
hello to every one. i have a question about kpis in SSAS. when i create a kpi with mdx language, the trend doesn't work because in the kpis browser panel we cannot give a cerrent member at the dimention of time. so we have to use reporting services to view how the trend works and if so hoa can i visualise the arrow in SSRS thank you in advance thnxs This tutorial might help you: http://www.databasejournal.com/features/mssql/article.php/3605826 Regards Thomas ...Show All
boaz_b Excel as Frontend to SSAS 2005 Cube
Hi, there, I am working on Excel as a front-end to a SSAS2005 cube. I intended to create a simple add-in that allows users to write back to the cube. Users will first retrieve data from the cube to pivot table and write back to the cube from the pivot table. I can find some sample source based on adodb and AS2000 but not adomd .net and SSAS2005. For the time being, information on SSAS2005 write-back from Excel seems very little. Not much references that I can refer to. Anyone can shed some light on this I would appreciate it if you can provide me some sample source in VBA using adomd .net or others that can demonstrate the write-back to a SSAS2005 cube. It would be great if the sample will be based on the AdventureWorksDW cube. Th ...Show All
