{"id":161,"date":"2011-09-06T07:57:15","date_gmt":"2011-09-06T07:57:15","guid":{"rendered":"http:\/\/graham-kendall.com\/blog\/?p=161"},"modified":"2020-09-22T01:59:03","modified_gmt":"2020-09-22T01:59:03","slug":"tracking-paper-downloads-database","status":"publish","type":"post","link":"https:\/\/graham-kendall.com\/blog\/tracking-paper-downloads-database\/","title":{"rendered":"Tracking Paper Downloads: Database"},"content":{"rendered":"<p>In my last post I outlined a few thoughts about tracking downloads of papers from the MISTA web site. Of course, the ideas can be used on any web site but I am particularly interested in MISTA at the moment.<\/p>\n<p>I have now started to develop the database, which will be a MySQL\u00a0 database which will be updated via PHP.<\/p>\n<p>The database design is still very much work in progress but my initial thoughts are to hold the following fields.<\/p>\n<p>The first table is the paper downloads table. This will hold the following:<\/p>\n<p><strong>id<\/strong>: Auto incrementing index just to track the number of downloads.<\/p>\n<p><strong>bibtex<\/strong>: This is the bibtex key of the paper that was requested. In the future I might use the doi (Digital Object Identifier) but bibtex is the best thing for me to uniquely identify apaper at the moment.<\/p>\n<p><strong>whenRequested<\/strong>: This is be a time stamp indicating when the request was received.<\/p>\n<p><strong>whenRetrieved<\/strong>: This is a time stamp indicating when the paper was actually downloaded.<\/p>\n<p><strong>accessCode<\/strong>: This will be a link between when the paper is requested and when it is retrieved. I will talk more about this in a later blog.<\/p>\n<p><strong>givenName<\/strong>: This is the given name of the person requesting the paper. As I said on my previous blog, I may not actually use this.<\/p>\n<p><strong>familyName<\/strong>: This is the family name of the person requesting the paper. As I said on my previous blog, I may not actually use this.<\/p>\n<p><strong>affiliation<\/strong>: This is the affiliation (university or company) of the person requesting the paper. As I said on my previous blog, I may not actually use this.<\/p>\n<p><strong>email<\/strong>: This is the email address of the person requesting the paper. This field will definitely be used.<\/p>\n<p><strong>retrieved<\/strong>: This is a boolean flag, indicating if the paper has been retrieved. I could use the retrieval date for this so I suppose I am breaking at least one the rules for defining a database, but I think a boolean flag is useful. I will outline the use of this flag in a later blog.<\/p>\n<p>&nbsp;<\/p>\n<p>There will be another table (papers). This will hold three fields:<\/p>\n<p><strong>bibtex<\/strong>: This is a unique identifier (for this table) which links it to the downloads table (above). Again, I could use the doi but, for now, I will use the bibtex key.<\/p>\n<p><strong>title<\/strong>: This is the title of the paper.<\/p>\n<p><strong>timesDownloaded<\/strong>: This will maintain a count of the number of times that the paper has ben downloaded. I could get it from the download table but having it stoed in this paper means that it is much quicker to access.<\/p>\n<p>&nbsp;<\/p>\n<p>These are my thoughts so far. As I say, very much work in progress and I have no doubts that it will change but, at lest, it&#8217;s a start.<\/p>\n<p>&nbsp;<\/p>\n<p>&nbsp;<\/p>\n","protected":false},"excerpt":{"rendered":"<p>In my last post I outlined a few thoughts about tracking downloads of papers from the MISTA web site. Of course, the ideas can be used on any web site but I am particularly interested in MISTA at the moment. I have now started to develop the database, which will be a MySQL\u00a0 database which [&hellip;]<\/p>\n","protected":false},"author":2,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[177,9,74,76,75,34],"tags":[78,77],"class_list":["post-161","post","type-post","status-publish","format-standard","hentry","category-archive","category-conference","category-database","category-digital-object-identifier","category-doi","category-mista","tag-database-design","tag-tracking-downloads-of-scientific-papers"],"_links":{"self":[{"href":"https:\/\/graham-kendall.com\/blog\/wp-json\/wp\/v2\/posts\/161","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/graham-kendall.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/graham-kendall.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/graham-kendall.com\/blog\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/graham-kendall.com\/blog\/wp-json\/wp\/v2\/comments?post=161"}],"version-history":[{"count":1,"href":"https:\/\/graham-kendall.com\/blog\/wp-json\/wp\/v2\/posts\/161\/revisions"}],"predecessor-version":[{"id":1675,"href":"https:\/\/graham-kendall.com\/blog\/wp-json\/wp\/v2\/posts\/161\/revisions\/1675"}],"wp:attachment":[{"href":"https:\/\/graham-kendall.com\/blog\/wp-json\/wp\/v2\/media?parent=161"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/graham-kendall.com\/blog\/wp-json\/wp\/v2\/categories?post=161"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/graham-kendall.com\/blog\/wp-json\/wp\/v2\/tags?post=161"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}