![]() It provides a rich API that enables you to. It can also help compare entire databases using only freeware tools, but again I would suggest investing in SQL Compare if you need to do this on a regular basis. Mergely is a JavaScript component for differencing and merging files interactively in a browser (diff/merge). It's an auditing tool for DDL events, but it also includes integration with Diff Merge which makes the task of comparing individual SPs a lot easier. If you are comparing individual SPs between databases, you might also find my TSQL DDL Code History tool useful. It makes the task of compare and synchronization simple - It is a commercial tool, but well worth the money if you need to compare on a regular basis. My advice would be to invest in a tool like Red Gate SQL Compare. This sort of thing would be easier to do properly in. Writing a function to parse your TSQL text and strip out insignificant whitespace isn't easy to do in T-SQL. The solution is incorrect because whitespace characters won't always be insignificant in your stored procedures. It will remove spaces and new line characters - you might also need to extend it to include other whitespace characters, but this is a starting point. REPLACE(REPLACE(REPLACE(Dest.Definition,' ',''),CHAR(13),''),CHAR(10),'') THEN 'Definition Mismatch' This parameter accepts wildcard LIKE also. * = Source Database = Destination Database Name with which the code has to be = For comparing the required object names only. SELECT so.name,so.create_date,so.modify_date,sm.definition ,so.type_descĮXEC To execute the procedure enter the Source DB and Destination DB name. ![]() ![]() ,''Destination Modify Date'' = Dest.modify_date ,''Destination Created Date'' = Dest.create_date ,''Source Modify Date'' = SRC.modify_date ,''Source Created Date'' = SRC.create_date WHEN SRC.Definition Dest.Definition THEN ''Definition Mismatch'' WHEN Dest.Definition is null THEN ''Missing in Destination'' WHEN SRC.Definition is null THEN ''Missing in Source'' ,''Object Type'' = ISNULL(SRC.type_desc,Dest.type_desc) SELECT ''Object Name'' = ISNULL(SRC.name,Dest.name) IF OBJECT_ID('CompareObjectCode','P') IS NOT NULL On m.object_id = p.object_id left outer join _modules R On p.name= s.name left outer join _modules M Select P.name as DB1, P.type,M.definition,s.name as DB2, r.definitionįrom P left outer join S Can someone modify these queries or give me some queries or suggestions of how to compare stored procedures only text. I do not know how to eliminate the blank space in comparsion of queries. The query works fine, But it is also taking the blank spaces into account and showing that the queries are not matching. I have the following scripts written and another from google. ![]() It seems putty is a bit more resilient to bad formatted version.I am trying to compare Stored procedures between two databases. I can properly send all the commands to this device via putty without noticing an error. Or do you have any option to make the protocol version exchange not so strict? I've also seen the other issues #769 and #761 related to this and tried out the newest version, but I'm still getting this error. The version information is not like specified in rfc4253. If you have a string of 8-bit ASCII characters, you can convert the letters in the string between upper and lower case by adding or subtracting 32 (decimal). I know that this device has the error because it seems to be sending a bad formatted version for the exchange. Ī server must not send a null character before the Protocol Version Exchange is complete.Īt .SocketReadLine(Socket socket, TimeSpan timeout, List`1 buffer)Īt .Start(String clientVersion, Socket socket, TimeSpan timeout)Īt () Exception occurred during SSH Client connect: : The server response contains a null character at position 0x0000000C:Ġ0000000 FF FB 03 FF FC 01 FF FE 01 FF FE 00. ![]()
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |