guid

Is it irresponsible to generate new Guids "willy nilly", and if so, or not, why?

in c#, at least, generating a new guid is a one line one call process. A guid is easy to use and format, and it "guarantees" uniqueness. However, is it irresponsible to just go off and generate new guids for every little thing. Could we be significantly increasing the chances of a "ta tan tan" guid collision?! thoughts...? ...

How's GUID determined?

How can applications ensure it's unique? ...

Identical hashes for a guid in both C# and javascript

I have a problem where I need to be able to generate identical uniformly distributed numeric hashs for a GUID in both javascript and C#. I guess that would prevent me from using Guid.GetHashCode() in C#, since I can't reproduce the behavior in JS without reverse engineering the C#. Is there a fast way to produce hashes from guids/string...

MyGuid.Equals(OtherGuid) IS NOT EQUAL ??

When I use MyGuid.ToString().Equals(OtherGuid.ToString()) they are Equal, why are they not equal when I compare the pure Guid ? Update: Well the problem here could be that I use a 3rd party control. The .Key below has a Guid and committeeId is a Guid too. They were never Equal only when I did ToString() on both Guid`s they were eq...

GUID: varchar(36) versus uniqueidentifier

I'm working with a legacy database that stores GUID values as a varchar(36) data type: CREATE TABLE T_Rows ( RowID VARCHAR(36) NOT NULL PRIMARY KEY, RowValue INT NOT NULL ) INSERT T_Rows (RowID, RowValue) VALUES (NEWID(), 1) I would assume that storing a GUID as a uniqueidentifier would be preferable since it's o...

How to generate a UUID of type long (to be consumed by a java program) in Python?

How do you generate UUID of type long (64 bits - to be consumed by a java program) using Python? I read about the UUID module. So I played with it a bit: >>> import uuid >>> uuid.uuid1().int 315596929882403038588122750660996915734L Why is there an "L" at the end of the integer generated by uuid.uuid1().int? If it's an integer should...

How to generate unique 64 bits integers from Python?

I need to generate unique 64 bits integers from Python. I've checked out the UUID module. But the UUID it generates are 128 bits integers. So that wouldn't work. Do you know of any way to generate 64 bits unique integers within Python? Thanks. ...

Single Sign On using Guid

How can I use a Guid for implementing single sign on the same domain? I can't use sessions as the different web apps would open in new windows hence loosing the session. Technology used: ASP.net 3.5, MVC2 architecture, C#. ...

Why do GUIDs and UUIDs have hyphens in them?

A colleague of mine was wondering why he couldn't just strip the hyphens from the uuid/guid before storing it. We couldn't work out what the hyphens were for... What is the reasoning behind them? Surely they'd make it less random? ...

Converting System.Decimal to System.Guid

I have a big dictionary where the key is decimal, but the GetHashCode() of System.Decimal is disasterously bad. To prove my guess, I ran a for loop with 100.000 neigboring decimals and checked the distribution. 100.000 different decimal numbers used only 2 (two!!!) different hashcodes. Decimal is represented as 16 bytes. Just like Guid!...

retrieving Odd values from a List<string> collection and saving them as GUID c#

Hello, I'm trying to retrieve odd values in a List of strings and convert them into a Guid Object. Here is what i came up with Guid oGuid = new Guid(); string objectName = string.Empty; for (int i = 0; i < lst_objectName_Guid.Count; i++) { if (i % 2 != 0) //The GUID values are in the Odd-Num...

Merge modules and the component GUID

I've read the http://robmensching.com/blog/posts/2003/10/18/Component-Rules-101 blogpost which is very enlightning. However, I still have some questions: What is the scope of a component GUID? How does all this relate when using mergemodules in different installers? Lets say I have two different installers, installing to different fol...

Windows GUID listings

I've been looking for a complete listing of important GUIDs the best I can find is http://www.myplugins.info/guids/guidlist.php although it seems like it is still missing some things like the GUID for IContextMenu. Would anyone know how to find these? Or is there a better listing of commonly used GUIDs in Windows? ...

Recreating a COM DLL, do I need to worry about the GUID?

A change needs to be made in a DLL. The DLL was originally coded in VB6 (not by me), and the source code lost. It is very simple in its functionality, so I recreated it from scratch, but I only have access to VB Express 2008. I created it first as a normal DLL then realized it had to be a COM DLL. Fortunately, an excellent article at h...

How securely unguessable are GUIDs?

A while ago I worked on a web application where users could buy tickets. Due to the way our client's processes worked, what you effectively got as a result of your purchase was a URL with the ticket number in it. These were tickets to buy property in the Middle East, and each ticket was potentially worth around $3,000,000. Clearly dishi...

SoapUI : is it possible to autogenerate the value from an element in a SOAP message ?

With SoapUI it's possible to send Soap XML message to a WCF service. I've the following SOAP message: <soap:Envelope xmlns:soap="http://www.w3.org/2003/05/soap-envelope" xmlns:my="http://myserviceprovider"&gt; <soap:Header/> <soap:Body> <my:ProcessOrder> <my:Orders> <my:Order> <my:id>rando...

Questions about GUID's: Are they always fixed in length, and is the middle number always 4?

I just generated a few million GUID's turned them into a String and got the length... it was always the same. Can I rely on this fixed length of the GUID when converting to String? Also, is the middle number of the GUID always "4" as shown in this screenshot? ...

Pictures Filenames - GUID or ID-based, When to use which

Hi, I tend to rename a profile user uploaded picture to the corresponding id of that column in the profile table, but recently i saw several projects adding an extra column in the table to identify the related photo (uniqueid, md5 or guid), what is the benefit of doing that, i see it redundant as i can already identify the photo with th...

How do I generate a number after a button is clicked?

Possible Duplicate: How to create a GUID / UUID in Javascript? I need to have a script that generates random numbers and letters with a form that looks like this: M3KRT-CKKYV-YH4G4-YXP42-46FMT Prefer jQuery, or javascript. I know how to generate number when the button is click using the .click() method in jQuery. But I can n...

Need to have duplicate item urls/GUIDs in RSS

I'm working on a tool to publish videos in a playlist, with the option to download as a podcast. Sometimes, items will need to be repeated over the course of the podcast. Having duplicate items or GUIDs causes problems though. Does anyone know of a way to be able to have duplicates? ...