Yes it is pretty simple. All database diagrams are stored in the table dtproperties. This link will show you the query you need to run. http://www.mssqlcity.com/FAQ/TranMove/MoveDiag.htm
notadood
Posts
-
Import diagram to SQL-server 2000 -
Automation ErrorIs this the second query that is failing? It looks like your syntax is for SQL Server, using wildcard %. If you are trying to wildcard it, and you are using Access your query needs to say: select * from configuracion where componente like '*s' Otherwise the query will never return any records.
-
plz tell how to get rid of database error?You need to build your sql string differently. The parameters are inside of your quote marks so the values can not be passed in. Depending on your datatypes it should look something more like: dim str as string str= "INSERT INTO employees Values(" + @ID + "," + @FN + "," + @LN + ")" dim InsCom as new SqlCommand(str,SqlConnection1) If your datatypes are int you may have to do something like str(@ID) as well as add single quotes if your datatypes are char.
-
SQL -> DOTNET data typesHere is part of it: SQL Server Data Types Corresponding VB Data Type http://www.tsqlsolutions.com/Articles/Index.cfm?ArticleID=9728
-
ADO.NET and DSNWe got around this by storing the database server name and database name in the registry. It is set during the installation of the program on the end computer.
-
List user tables in a database??Try selecting it from the INFORMATION_SCHEMA views directly. SELECT * FROM INFORMATION_SCHEMA.TABLES WHERE TABLE_NAME <> 'dtproperties' AND TABLE_TYPE = 'BASE TABLE' ORDER BY 1
-
SQL DebuggingProfiler wouldn't really be much help for debugging. It is mainly good for finding performance bottlenecks & problems. I have had good success on debugging in Query Analyzer using the method described above. You can run the procedure straight out of QA and put exit points at various points if necessary - using the RETURN statement. Once you get used to it you can debug relatively quickly.
-
Import/Export problemYes, I would just do it a bit at a time. Since you are having problems with the views do the tables and data first. Once they are there it is easy enough just to go back and script the views and procedures. Also see: http://www.microsoft.com/sql/techinfo/tips/administration/changingcodepage.asp
-
Import/Export problemCan you explain what you are trying to do? Maybe the view is based on tables that do not exist in the location you are trying to create the view in.
-
SQL DebuggingThe method I use to debug a procedure is to put print statements throughout the procedure so you can see what the values you are getting really are. It's a clunky method but usually works well. Most procedures are not that complicated. You have to do this in Query Analyzer. If you have specific statements you are having problems with paste them here.
-
SQL - SELECT DISTINCT myfieldIf I am reading this thread correctly than you should be able to use the GROUP BY clause. It does the same thing as DISTINCT but uses a different format. It would look something like: SELECT CUSTOMER_NAME, ID, CHECKED, FOUNDWITH, URL FROM Emails WHERE CHECKED= False GROUP BY CUSTOMER_NAME, ID, CHECKED, FOUNDWITH, URL ORDER BY FOUNDWITH
-
Whats wrong with this picture?The procedure probably does not return one recordset. Your other option is to create a SQL statement using UNION and put the select in for each table name.
-
Stored Procedure and Jobssp_start_job [@job_name =] 'job_name' | [@job_id =] job_id [,[@error_flag =] error_flag] [,[@server_name =] 'server_name'] [,[@step_name =] 'step_name'] [,[@output_flag =] output_flag] where [@job_name =] 'job_name' is the name of the job to start. [@job_id =] job_id is the identification number of the job to start. [@error_flag =] error_flag is "reserved" [@server_name =] 'server_name' is the target server on which to start the job. [@step_name =] 'step_name' is the name of the step at which to begin execution of the job and applies only to local jobs. The return code values are 0 (success) or 1 (failure). This example starts a job named Nightly Backup: USE msdb EXEC sp_start_job @job_name = 'Nightly Backup'
-
SELECT from multiple tables in a DBYou can start with this: sp_MSforeachtable 'select * from ?' and then customize the select with whatever you want.
-
retrieve column lengthIf you are using SQL Server then: SELECT CHARACTER_MAXIMUM_LENGTH FROM INFORMATION_SCHEMA.COLUMNS WHERE TABLE_NAME = 'yourtablename' AND COLUMN_NAME = 'your column name'
-
what men should knowright on brother!
-
what men should knowActually I was searching for some SQL DMO code and came across the previous posting. Since there are not many girls who know how to spell SQL much less code DMO, I figured I would join this circus. You know, when in Rome... ;P
-
what men should know1. Skid marks are not attractive. Learn to wipe yourself. If you can't, the bathroom has a hamper for dirty clothes, try getting the skid mark underwear in it 1. Going to the bathroom with a newspaper under your arm at work is more than obvious that you're going to take a dump. be a little less conspicuous 1. Don't ask us if your hair is getting thin if you don't want to hear the answer. 1. You can either ask us to do something or tell us how you want it done. Not both. If you already know best how to do it then just do it yourself. 1. If it itches, you might want to use soap and water to clean it first. 1. "I am in shape. round is a shape" Round means you are fat. lose some weight. Lay off the beer. If you expect us to look like Victoria secret models, you can expect us to want you to look like a soap star. And finally, Thank you for sleeping on the couch. I was able to sleep without the snoring. ;P