<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
		<id>https://xmlpipedb.lmucs.io/biodb/fall2015/index.php?action=history&amp;feed=atom&amp;title=Jkuroda_Week_6</id>
		<title>Jkuroda Week 6 - Revision history</title>
		<link rel="self" type="application/atom+xml" href="https://xmlpipedb.lmucs.io/biodb/fall2015/index.php?action=history&amp;feed=atom&amp;title=Jkuroda_Week_6"/>
		<link rel="alternate" type="text/html" href="https://xmlpipedb.lmucs.io/biodb/fall2015/index.php?title=Jkuroda_Week_6&amp;action=history"/>
		<updated>2026-05-03T16:22:40Z</updated>
		<subtitle>Revision history for this page on the wiki</subtitle>
		<generator>MediaWiki 1.25.1</generator>

	<entry>
		<id>https://xmlpipedb.lmucs.io/biodb/fall2015/index.php?title=Jkuroda_Week_6&amp;diff=2812&amp;oldid=prev</id>
		<title>Jkuroda: template</title>
		<link rel="alternate" type="text/html" href="https://xmlpipedb.lmucs.io/biodb/fall2015/index.php?title=Jkuroda_Week_6&amp;diff=2812&amp;oldid=prev"/>
				<updated>2015-10-20T04:13:32Z</updated>
		
		<summary type="html">&lt;p&gt;template&lt;/p&gt;
&lt;table class=&#039;diff diff-contentalign-left&#039;&gt;
				&lt;col class=&#039;diff-marker&#039; /&gt;
				&lt;col class=&#039;diff-content&#039; /&gt;
				&lt;col class=&#039;diff-marker&#039; /&gt;
				&lt;col class=&#039;diff-content&#039; /&gt;
				&lt;tr style=&#039;vertical-align: top;&#039;&gt;
				&lt;td colspan=&#039;2&#039; style=&quot;background-color: white; color:black; text-align: center;&quot;&gt;← Older revision&lt;/td&gt;
				&lt;td colspan=&#039;2&#039; style=&quot;background-color: white; color:black; text-align: center;&quot;&gt;Revision as of 04:13, 20 October 2015&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot; id=&quot;L344&quot; &gt;Line 344:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 344:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&#039;diff-marker&#039;&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;#160; select sponsorApplicant from application inner join product on (product.applNumber = application.id) where&lt;/div&gt;&lt;/td&gt;&lt;td class=&#039;diff-marker&#039;&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;#160; select sponsorApplicant from application inner join product on (product.applNumber = application.id) where&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&#039;diff-marker&#039;&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;#160; (sponsorApplicant like &amp;#039;%LABS%&amp;#039; and product.activeIngredient like &amp;#039;%CAFFEINE%&amp;#039; and activeIngredient like &amp;#039;%ASPIRIN%&amp;#039;)&lt;/div&gt;&lt;/td&gt;&lt;td class=&#039;diff-marker&#039;&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;#160; (sponsorApplicant like &amp;#039;%LABS%&amp;#039; and product.activeIngredient like &amp;#039;%CAFFEINE%&amp;#039; and activeIngredient like &amp;#039;%ASPIRIN%&amp;#039;)&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot;&gt;&amp;#160;&lt;/td&gt;&lt;td class=&#039;diff-marker&#039;&gt;+&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot;&gt;&amp;#160;&lt;/td&gt;&lt;td class=&#039;diff-marker&#039;&gt;+&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;{{Template:Journal Template}}&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;/table&gt;</summary>
		<author><name>Jkuroda</name></author>	</entry>

	<entry>
		<id>https://xmlpipedb.lmucs.io/biodb/fall2015/index.php?title=Jkuroda_Week_6&amp;diff=2564&amp;oldid=prev</id>
		<title>Jkuroda: edits</title>
		<link rel="alternate" type="text/html" href="https://xmlpipedb.lmucs.io/biodb/fall2015/index.php?title=Jkuroda_Week_6&amp;diff=2564&amp;oldid=prev"/>
				<updated>2015-10-15T05:12:58Z</updated>
		
		<summary type="html">&lt;p&gt;edits&lt;/p&gt;
&lt;a href=&quot;https://xmlpipedb.lmucs.io/biodb/fall2015/index.php?title=Jkuroda_Week_6&amp;amp;diff=2564&amp;amp;oldid=2500&quot;&gt;Show changes&lt;/a&gt;</summary>
		<author><name>Jkuroda</name></author>	</entry>

	<entry>
		<id>https://xmlpipedb.lmucs.io/biodb/fall2015/index.php?title=Jkuroda_Week_6&amp;diff=2500&amp;oldid=prev</id>
		<title>Jkuroda: first edit</title>
		<link rel="alternate" type="text/html" href="https://xmlpipedb.lmucs.io/biodb/fall2015/index.php?title=Jkuroda_Week_6&amp;diff=2500&amp;oldid=prev"/>
				<updated>2015-10-15T03:31:28Z</updated>
		
		<summary type="html">&lt;p&gt;first edit&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;==Creating Tables==&lt;br /&gt;
&lt;br /&gt;
To begin the assignment, I first downloaded pgAdmin3 to my computer and created my own database with which I could work. I used the curl command in the terminal to download the FDA files to my directory in &amp;lt;code&amp;gt;my.cs.lmu.edu&amp;lt;/code&amp;gt; then I set up the tables for both the application and product lists using the following commands:&lt;br /&gt;
 create table application (id int primary key, applicationType varchar, sponsorApplicant varchar, &lt;br /&gt;
 mostRecentLabelAvailableFlag boolean, currentPatentFlag boolean, actionType varchar, chemicalType int, &lt;br /&gt;
 therPotential varchar, orphanCode varchar)&lt;br /&gt;
&lt;br /&gt;
 create table product (int references application(id), productNumber int, form varchar, dosage varchar, &lt;br /&gt;
 productMktStatus int, TECode varchar, referenceDrug int, drugName varchar, activeIngredient varchar)&lt;br /&gt;
&lt;br /&gt;
==SQL Insert Statements==&lt;br /&gt;
&lt;br /&gt;
Now I had to get the data from the FDA into these formatted tables, so I drew upon my experience from using the command line in previous weeks and came up with the following:&lt;br /&gt;
&lt;br /&gt;
 cat application.txt | sed &amp;quot;1D&amp;quot; | sed &amp;quot;s/\t/&amp;#039;,&amp;#039;/g&amp;quot; | sed &amp;quot;s/\r$/&amp;#039;);/g&amp;quot; | sed &amp;quot;s/ *&amp;#039;/&amp;#039;/g&amp;quot; | &lt;br /&gt;
 sed &amp;quot;s/&amp;#039;&amp;#039;/null/g&amp;quot; | sed &amp;quot;s/&amp;#039;//1&amp;quot; | sed &amp;quot;s/^/insert into&lt;br /&gt;
 application(id,applicationType,sponsorApplicant,mostRecentLabelAvailableFlag,&lt;br /&gt;
 currentPatentFlag,actionType,chemicalType,therPotential,orphanCode)/g&amp;quot; &amp;gt; ~/public_html/application.sql.txt&lt;/div&gt;</summary>
		<author><name>Jkuroda</name></author>	</entry>

	</feed>