guid

Persistent unique ID for Chrome tabs that lasts between browser sessions

家住魔仙堡 提交于 2019-11-30 07:24:52
I'm trying to ascertain some way to establish a unique ID for Chrome tabs that meets the following conditions: Uniquely identifies each tab Stays the same for a given tab between browser restarts (session-restored tabs) Stays the same if a tab is closed and then reopened with Undo Closed Tab (Ctrl+Shift+T) Stays distinct if a tab is duplicated I've done some rather aggressive research to find a comprehensive solution, but nothing seems to quite do the trick. Here are the methods I have tried, in increasing order of efficacy: Use Chrome's provided tab.id: does not persist between browser

How should I store a GUID in Oracle?

假装没事ソ 提交于 2019-11-30 06:24:30
问题 I am coming from the SQL server world where we had uniqueidentifier. Is there an equivalent in oracle? This column will be frequently queried so performance is the key. I am generating the GUID in .Net and will be passing it to Oracle. For a couple reasons it cannot be generated by oracle so I cannot use sequence. 回答1: CREATE table test (testguid RAW(16) default SYS_GUID() ) This blog studied the relative performance. 回答2: As others have stated, there is a performance hit using GUIDs compared

Generate a UUID on iOS from Swift

你说的曾经没有我的故事 提交于 2019-11-30 06:08:08
问题 In my iOS Swift app I want to generate random UUID ( GUID ) strings for use as a table key, and this snippet appears to work: let uuid = CFUUIDCreateString(nil, CFUUIDCreate(nil)) Is this safe? Or is there perhaps a better (recommended) approach? 回答1: Try this one: let uuid = NSUUID().uuidString print(uuid) Swift 3/4 let uuid = UUID().uuidString print(uuid) 回答2: You could also just use the NSUUID API: let uuid = NSUUID() If you want to get the string value back out, you can use uuid

SQL Server - Guid VS. Long

橙三吉。 提交于 2019-11-30 04:06:40
Up until now i've been using the C# "Guid = Guid.NewGuid();" method to generate a unique ID that can be stored as the ID field in some of my SQL Server database tables using Linq to SQL. I've been informed that for indexing reasons, using a GUID is a bad idea and that I should use an auto-incrementing Long instead. Will using a long speed up my database transactions? If so, how do I go about generating unique ID's that are of type Long? Regards, Both have pros and cons, it depends entirely on how you use them that matters. Right off the bat, if you need identifiers that can work across several

Convert byte array from Oracle RAW to System.Guid?

天大地大妈咪最大 提交于 2019-11-30 03:25:47
问题 My app interacts with both Oracle and SQL Server databases using a custom data access layer written in ADO.NET using DataReaders. Right now I'm having a problem with the conversion between GUIDs (which we use for primary keys) and the Oracle RAW datatype. Inserts into oracle are fine (I just use the ToByteArray() method on System.Guid). The problem is converting back to System.Guid when I load records from the database. Currently, I'm using the byte array I get from ADO.NET to pass into the

What are the project GUIDs in a Visual Studio solution file used for?

纵饮孤独 提交于 2019-11-30 02:39:39
I have multiple projects in a single Visual Studio (2008) solution. I just discovered that each of these projects uses a same GUID, so in the solution file it looks like this: Project("{FAE04EC0-F103-D311-BF4B-00C04FCBFE97}") = "Pro1", "Pro1\Pro1.csproj", "{...}" Project("{FAE04EC0-F103-D311-BF4B-00C04FCBFE97}") = "Pro2", "Pro2\Pro2.csproj", "{...}" Do I have to change these GUIDs so they're unique and what are they used for? Project persistence block in a solution file has the following format: Project("{project type GUID}") = "<Project name>", "<project file location>", "{<Unique project

How to validate GUID is a GUID

China☆狼群 提交于 2019-11-30 02:34:24
How to determine if a string contains a GUID vs just a string of numbers. will a GUID always contain at least 1 alpha character? Deepesh See if these helps :- Guid guidResult = Guid.Parse(inputString) ( http://msdn.microsoft.com/en-us/library/system.guid.parse.aspx ) bool isValid = Guid.TryParse(inputString, out guidOutput) http://msdn.microsoft.com/en-us/library/system.guid.tryparse.aspx There is no guarantee that a GUID contains alpha characters. FFFFFFFF-FFFF-FFFF-FFFF-FFFFFFFFFFFF is a valid GUID so is 00000000-0000-0000-0000-000000000000 and anything in between. If you are using .NET 4.0,

Validation of Guid

ⅰ亾dé卋堺 提交于 2019-11-30 01:23:15
问题 I have a strongly-typed view which has a DropDownListFor attribute on it. Each item in the dropdown list is represented by a GUID. What I'm after is a way to validate if a user selects an item from the dropdown list. At present i don't see anyway of doing this using Data Annotations. Is there anyway of achieving this using Data Annotations so client and server side validation would work. I'm guessing i need to make a custom method to do this but was wondering if anything already existed. 回答1:

Is Guid the best identity datatype for Databases?

给你一囗甜甜゛ 提交于 2019-11-29 23:18:14
It is connected to BI and merging of data from different data sources and would make that process more smooth. And is there an optimal migration strategy from a database without Guids to a version with Guids without information losses? Edited after reading Frans Bouma's answer, since my answer has been accepted and therefore moved to the top. Thanks, Frans. GUIDs do make a good unique value, however due to their complex nature they're not really human-readable, which can make support difficult. If you're going to use GUIDs you might want to consider doing some performance analysis on bulk data

What is COM?

情到浓时终转凉″ 提交于 2019-11-29 22:23:41
I searched hard, but was unable to grasp the whole idea. Can anyone tell me: What COM actually is? How do GUIDs work, and how are they used by COM? How does COM resolve the issues of different DLL versions. Or at least, point me to a good article somewhere that explains these concepts? Thanks! Charles Bretana COM is "Component Object Model". It is one of the first technologies designed to allow "binary reuse" of components... Originally, it was the rewrite of what was, in Microsoft Office circa 1988-1992 time frame, referred to as Dynamic Data Exchange (DDE), a technology designed to allow the