{
  "id": 66056,
  "title": "Understanding VisitId vs SessionID",
  "url": "/competitions/ga-customer-revenue-prediction/discussion/66056",
  "author_name": "",
  "post_date": "2018-09-17T19:21:50.965833200Z",
  "votes": null,
  "comment_count": 6,
  "views": 0,
  "content": "<p>So from the data section of the competition:</p>\n\n<p><strong>sessionId</strong> - A unique identifier for this visit to the store.\n<strong>visitId</strong> - An identifier for this session. This is part of the value usually stored as the _utmb cookie. This is only unique to the user. For a completely unique ID, you should use a combination of fullVisitorId and visitId.</p>\n\n<p>Now, it may just be me, but it seems to me like these two are referring to one and the same. Does someone have a clear explanation of the difference between these two?</p>",
  "messages": [
    {
      "id": "388892",
      "postDate": "09/17/2018 19:21:50",
      "content": "<p>So from the data section of the competition:</p>\n\n<p><strong>sessionId</strong> - A unique identifier for this visit to the store.\n<strong>visitId</strong> - An identifier for this session. This is part of the value usually stored as the _utmb cookie. This is only unique to the user. For a completely unique ID, you should use a combination of fullVisitorId and visitId.</p>\n\n<p>Now, it may just be me, but it seems to me like these two are referring to one and the same. Does someone have a clear explanation of the difference between these two?</p>",
      "rawMarkdown": "So from the data section of the competition:\n\n**sessionId** - A unique identifier for this visit to the store.\n**visitId** - An identifier for this session. This is part of the value usually stored as the _utmb cookie. This is only unique to the user. For a completely unique ID, you should use a combination of fullVisitorId and visitId.\n\nNow, it may just be me, but it seems to me like these two are referring to one and the same. Does someone have a clear explanation of the difference between these two?",
      "votes": null
    },
    {
      "id": "388896",
      "postDate": "09/17/2018 19:32:15",
      "content": "<p>I think there is no difference between session id and the combination of fullvisitor id and visit id.</p>\n\n<pre><code>(train['sessionId']==train['fullVisitorId']+\"_\"+train['visitId'].astype(str)).value_counts()\n</code></pre>\n\n<p>The above one outputs true as the length of train data.</p>\n\n<p>But interesting point is that session id is not unique. There are some rows which have same session id. I dont know why it so</p>",
      "rawMarkdown": "I think there is no difference between session id and the combination of fullvisitor id and visit id.\n\n    (train['sessionId']==train['fullVisitorId']+\"_\"+train['visitId'].astype(str)).value_counts()\n\nThe above one outputs true as the length of train data.\n\nBut interesting point is that session id is not unique. There are some rows which have same session id. I dont know why it so",
      "votes": null
    },
    {
      "id": "388898",
      "postDate": "09/17/2018 19:37:14",
      "content": "<p>Good catch on the format.\nAlso, yes, I played with the data. The only way to create a truly unique id is by combining the date and sessionId.</p>",
      "rawMarkdown": "Good catch on the format.\nAlso, yes, I played with the data. The only way to create a truly unique id is by combining the date and sessionId.",
      "votes": null
    },
    {
      "id": "388964",
      "postDate": "09/17/2018 22:54:37",
      "content": "<p>I agree the names are confusing. It might have been better to call it fullVisitID == visitorID +_+ sessionID. No big deal though, this looks to be a fun one.</p>",
      "rawMarkdown": "I agree the names are confusing. It might have been better to call it fullVisitID == visitorID +_+ sessionID. No big deal though, this looks to be a fun one.",
      "votes": null
    },
    {
      "id": "391642",
      "postDate": "09/22/2018 06:35:34",
      "content": "<p>Because you can have a session active and visit the page multiple times over the course of time withouit actually logging in , that i believe incrments the visitor counter</p>",
      "rawMarkdown": "Because you can have a session active and visit the page multiple times over the course of time withouit actually logging in , that i believe incrments the visitor counter",
      "votes": null
    },
    {
      "id": "391764",
      "postDate": "09/22/2018 11:39:58",
      "content": "<p>But you can see the visit start time of two sessions(which have session id) are different and not even near </p>",
      "rawMarkdown": "But you can see the visit start time of two sessions(which have session id) are different and not even near",
      "votes": null
    },
    {
      "id": "392144",
      "postDate": "09/23/2018 05:26:10",
      "content": "<p>I did not take a look at that , will do that  , however does that not imply the visits are not so frequent ?</p>",
      "rawMarkdown": "I did not take a look at that , will do that  , however does that not imply the visits are not so frequent ?",
      "votes": null
    }
  ],
  "comments": [
    {
      "id": 388896,
      "author_name": "suchith0312",
      "author_url": "",
      "post_date": "09/17/2018 19:32:15",
      "content": "<p>I think there is no difference between session id and the combination of fullvisitor id and visit id.</p>\n\n<pre><code>(train['sessionId']==train['fullVisitorId']+\"_\"+train['visitId'].astype(str)).value_counts()\n</code></pre>\n\n<p>The above one outputs true as the length of train data.</p>\n\n<p>But interesting point is that session id is not unique. There are some rows which have same session id. I dont know why it so</p>",
      "votes": null,
      "replies": [
        {
          "id": 388898,
          "author_name": "arisosnovsky",
          "author_url": "",
          "post_date": "09/17/2018 19:37:14",
          "content": "<p>Good catch on the format.\nAlso, yes, I played with the data. The only way to create a truly unique id is by combining the date and sessionId.</p>",
          "votes": null,
          "replies": []
        },
        {
          "id": 391642,
          "author_name": "arbardhan",
          "author_url": "",
          "post_date": "09/22/2018 06:35:34",
          "content": "<p>Because you can have a session active and visit the page multiple times over the course of time withouit actually logging in , that i believe incrments the visitor counter</p>",
          "votes": null,
          "replies": []
        },
        {
          "id": 391764,
          "author_name": "suchith0312",
          "author_url": "",
          "post_date": "09/22/2018 11:39:58",
          "content": "<p>But you can see the visit start time of two sessions(which have session id) are different and not even near </p>",
          "votes": null,
          "replies": []
        },
        {
          "id": 392144,
          "author_name": "arbardhan",
          "author_url": "",
          "post_date": "09/23/2018 05:26:10",
          "content": "<p>I did not take a look at that , will do that  , however does that not imply the visits are not so frequent ?</p>",
          "votes": null,
          "replies": []
        }
      ]
    },
    {
      "id": 388964,
      "author_name": "jpmiller",
      "author_url": "",
      "post_date": "09/17/2018 22:54:37",
      "content": "<p>I agree the names are confusing. It might have been better to call it fullVisitID == visitorID +_+ sessionID. No big deal though, this looks to be a fun one.</p>",
      "votes": null,
      "replies": []
    }
  ],
  "raw_markdown_by_id": {
    "388892": "So from the data section of the competition:\n\n**sessionId** - A unique identifier for this visit to the store.\n**visitId** - An identifier for this session. This is part of the value usually stored as the _utmb cookie. This is only unique to the user. For a completely unique ID, you should use a combination of fullVisitorId and visitId.\n\nNow, it may just be me, but it seems to me like these two are referring to one and the same. Does someone have a clear explanation of the difference between these two?",
    "388896": "I think there is no difference between session id and the combination of fullvisitor id and visit id.\n\n    (train['sessionId']==train['fullVisitorId']+\"_\"+train['visitId'].astype(str)).value_counts()\n\nThe above one outputs true as the length of train data.\n\nBut interesting point is that session id is not unique. There are some rows which have same session id. I dont know why it so",
    "388898": "Good catch on the format.\nAlso, yes, I played with the data. The only way to create a truly unique id is by combining the date and sessionId.",
    "388964": "I agree the names are confusing. It might have been better to call it fullVisitID == visitorID +_+ sessionID. No big deal though, this looks to be a fun one.",
    "391642": "Because you can have a session active and visit the page multiple times over the course of time withouit actually logging in , that i believe incrments the visitor counter",
    "391764": "But you can see the visit start time of two sessions(which have session id) are different and not even near",
    "392144": "I did not take a look at that , will do that  , however does that not imply the visits are not so frequent ?"
  },
  "source": "meta"
}