<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>./klaus hofeditz :: weblog</title>
	<atom:link href="http://blog.klaushofeditz.de/?feed=rss2" rel="self" type="application/rss+xml" />
	<link>http://blog.klaushofeditz.de</link>
	<description>Thoughts on ]po[, technology and business</description>
	<lastBuildDate>Thu, 02 Sep 2010 10:19:19 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0.1</generator>
		<item>
		<title>2010-09-02</title>
		<link>http://blog.klaushofeditz.de/?p=349</link>
		<comments>http://blog.klaushofeditz.de/?p=349#comments</comments>
		<pubDate>Thu, 02 Sep 2010 10:19:19 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[Database]]></category>

		<guid isPermaLink="false">http://blog.klaushofeditz.de/?p=349</guid>
		<description><![CDATA[How b-tree database indexes work and how to tell if they are efficient (100&#8242; level)]]></description>
			<content:encoded><![CDATA[<ul>
<li><a href="http://mattfleming.com/node/192">How b-tree database indexes work and how to tell if they are efficient (100&#8242; level)</a></li>
</ul>
]]></content:encoded>
			<wfw:commentRss>http://blog.klaushofeditz.de/?feed=rss2&amp;p=349</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>2010-08-17</title>
		<link>http://blog.klaushofeditz.de/?p=327</link>
		<comments>http://blog.klaushofeditz.de/?p=327#comments</comments>
		<pubDate>Tue, 17 Aug 2010 20:45:09 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://blog.klaushofeditz.de/?p=327</guid>
		<description><![CDATA[Investment in Open Source Software Set to Rise, Accenture Survey Finds How many people do you know that build not only one, but two very successful companies?PODCAST &#8211; Marc Andreessen:A Panorama of Venture Capital and Beyond]]></description>
			<content:encoded><![CDATA[<ul>
<li><a href="http://www.marketwatch.com/story/investment-in-open-source-software-set-to-rise-accenture-survey-finds-2010-08-05?reflink=MW_news_stmp,">Investment in Open Source Software Set to Rise, Accenture Survey Finds</a>
</li>
<li>How many people do you know that build not only one, but two very successful companies?<br /><a href="http://ecorner.stanford.edu/authorMaterialInfo.html?mid=2373">PODCAST &#8211; Marc Andreessen:A Panorama of Venture Capital and Beyond</a></li>
</ul>
]]></content:encoded>
			<wfw:commentRss>http://blog.klaushofeditz.de/?feed=rss2&amp;p=327</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>GUI elements we&#8217;d love to see in ]po[ 4.x</title>
		<link>http://blog.klaushofeditz.de/?p=306</link>
		<comments>http://blog.klaushofeditz.de/?p=306#comments</comments>
		<pubDate>Sat, 17 Jul 2010 13:52:40 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[]po[]]></category>
		<category><![CDATA[]po[ Development]]></category>
		<category><![CDATA[]po[ and AJAX]]></category>
		<category><![CDATA[]po[ for SMB's]]></category>

		<guid isPermaLink="false">http://blog.klaushofeditz.de/?p=306</guid>
		<description><![CDATA[Search Box with Filter and Large Drop Down Menu http://tympanus.net/codrops/2010/07/14/ui-elements-search-box/ http://www.web-delicious.com/jquery-plugins/]]></description>
			<content:encoded><![CDATA[<p>Search Box with Filter and Large Drop Down Menu</p>
<p>http://tympanus.net/codrops/2010/07/14/ui-elements-search-box/</p>
<p>http://www.web-delicious.com/jquery-plugins/</p>
]]></content:encoded>
			<wfw:commentRss>http://blog.klaushofeditz.de/?feed=rss2&amp;p=306</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Autocomplete anywhere &#8211; includes emacs</title>
		<link>http://blog.klaushofeditz.de/?p=291</link>
		<comments>http://blog.klaushofeditz.de/?p=291#comments</comments>
		<pubDate>Wed, 14 Apr 2010 11:21:51 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[Productivity]]></category>
		<category><![CDATA[]po[ Development]]></category>

		<guid isPermaLink="false">http://blog.klaushofeditz.de/?p=291</guid>
		<description><![CDATA[http://www.autohotkey.com/ http://www.vasanth.in/content/binary/Intellitype.ahk http://www.autohotkey.com/docs/scripts/ http://www.donationcoder.com/Software/Skrommel/index.html#AutoClip]]></description>
			<content:encoded><![CDATA[<p>http://www.autohotkey.com/</p>
<p>http://www.vasanth.in/content/binary/Intellitype.ahk</p>
<p>http://www.autohotkey.com/docs/scripts/</p>
<p>http://www.donationcoder.com/Software/Skrommel/index.html#AutoClip</p>
]]></content:encoded>
			<wfw:commentRss>http://blog.klaushofeditz.de/?feed=rss2&amp;p=291</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Common constructs writing ]po[ update scripts</title>
		<link>http://blog.klaushofeditz.de/?p=284</link>
		<comments>http://blog.klaushofeditz.de/?p=284#comments</comments>
		<pubDate>Wed, 17 Mar 2010 18:34:15 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[]po[ Development]]></category>
		<category><![CDATA[]po[ SysAdmin]]></category>

		<guid isPermaLink="false">http://blog.klaushofeditz.de/?p=284</guid>
		<description><![CDATA[Sample Script create or replace function inline_0 () returns integer as ' declare v_count integer; begin select count(*) into v_count from user_tab_columns where lower(table_name) = ''acs_object_types'' and lower(column_name) = ''icon_path''; IF v_count > 0 THEN return 1; END IF; alter table acs_object_types add column icon_path character varying(100); RETURN 0; end;' language 'plpgsql'; select inline_0 (); [...]]]></description>
			<content:encoded><![CDATA[<h2>Sample Script</h2>
<pre>
create or replace function inline_0 ()
returns integer as '
declare
        v_count         integer;
begin
        select count(*) into v_count from user_tab_columns
        where lower(table_name) = ''acs_object_types'' and lower(column_name) = ''icon_path'';
        IF v_count > 0 THEN return 1; END IF;

        alter table acs_object_types add column icon_path character varying(100);
        RETURN 0;

end;' language 'plpgsql';
select inline_0 ();
drop function inline_0 ();
</pre>
<h2>Check existence of column:</h2>
<pre>select count(*) into v_count from user_tab_columns where table_name = ''IM_HOURS'' and column_name = ''INVOICE_ID'';</pre>
<h2>Check existence of table:</h2>
<pre>select count(*) into v_count from pg_tables where tablename = ''im_capacity_planning'';</pre>
<h2>Check for existing constraints</h2>
<pre>
        select count(*) into v_count from pg_constraint
        where lower(conname) = ''im_hours_project_fk'';
</pre>
<h2>Create categories</h2>
<pre>SELECT im_category_new (16006, 'Rejected', 'Intranet Absence Status');</pre>
<h2>Create menu item</h2>
<pre>
SELECT im_new_menu(
        'intranet-timesheet2',
        'timesheet2_absences_bankholiday',
        'New Bank Holiday',
        '/intranet-timesheet2/absences/new?absence_type_id=5004',
        50,
        'timesheet2_absences',
        null
);
</pre>
<h2> Create menu permissions</h2>
<pre>SELECT im_new_menu_perms('timesheet2_absences_bankholiday', 'Employees');</pre>
]]></content:encoded>
			<wfw:commentRss>http://blog.klaushofeditz.de/?feed=rss2&amp;p=284</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>pg_dump failed &#8211; invalid byte sequence for encoding &#8220;UTF8&#8243;</title>
		<link>http://blog.klaushofeditz.de/?p=281</link>
		<comments>http://blog.klaushofeditz.de/?p=281#comments</comments>
		<pubDate>Fri, 19 Feb 2010 23:14:09 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[]po[ SysAdmin]]></category>

		<guid isPermaLink="false">http://blog.klaushofeditz.de/?p=281</guid>
		<description><![CDATA[Using pg_dump -U projop -E UTF8 -d projop > projop.dump instead of the usual pg_dump --no-owner --clean --disable-dollar-quoting --format=p --file projop.dump I was able to to restore the db.]]></description>
			<content:encoded><![CDATA[<p>Using</p>
<pre>pg_dump -U projop -E UTF8 -d projop > projop.dump</pre>
<p>instead of the usual</p>
<pre>pg_dump --no-owner --clean --disable-dollar-quoting --format=p --file projop.dump</pre>
<p>I was able to to restore the db. </p>
]]></content:encoded>
			<wfw:commentRss>http://blog.klaushofeditz.de/?feed=rss2&amp;p=281</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>BCN tips</title>
		<link>http://blog.klaushofeditz.de/?p=261</link>
		<comments>http://blog.klaushofeditz.de/?p=261#comments</comments>
		<pubDate>Wed, 18 Nov 2009 13:15:16 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[Barcelona]]></category>

		<guid isPermaLink="false">http://blog.klaushofeditz.de/?p=261</guid>
		<description><![CDATA[Restaurants Classics http://www.loscaracoles.es/ Barcelona classic, nice &#8216;ambiente&#8217;, very touristic, prices maybe a bit to high for what they offer, but you get the whole spanish experience, crossing the kitchen when entering the restaurant, always packed with people, hams hanging from the ceiling. Cervecería Catalana My favorite tapa place Senyor Parellada http://www.senyorparellada.com/ Classic in the born [...]]]></description>
			<content:encoded><![CDATA[<h1>Restaurants</h1>
<h2>Classics</h2>
<p><a href="http://www.loscaracoles.es/">http://www.loscaracoles.es/</a><br />
Barcelona classic, nice &#8216;ambiente&#8217;, very touristic, prices maybe a bit to high for what they offer, but you get the whole spanish experience,  crossing the kitchen when entering the restaurant, always packed with people, hams hanging from the ceiling.  </p>
<p><a href="http://travel.yahoo.com/p-travelguide-2790032-cerveceria_catalana_barcelona-i">Cervecería Catalana</a><br />
My favorite tapa place</p>
<p>Senyor Parellada</p>
<p>http://www.senyorparellada.com/</p>
<p>Classic in the born area </p>
<h2>&#8220;Elegancia&#8221;</h2>
<p><a href="http://www.rte-olive.com/">http://www.rte-olive.com/</a><br />
Take your beloved one to this on her birthday </p>
<p>http://www.hotelcasafuster.com/restaurante.asp</p>
<p>Take your beloved one to this in case you want to propose &#8211; Woddy Allen played the saxophon during his stays in the bar</p>
<p>http://www.ladama-restaurant.com/</p>
<p>Back to the good old days, upper price segment.<br />
(&#8230; you have one of the best TROBADORS right across the street)</p>
<h2>Modern</h2>
<p>http://www.w-barcelona.com/</p>
<p>impressive !!!</p>
<p>Hesperia_Tower-Barcelona_Catalonia</p>
<p>http://www.tripadvisor.es/Hotel_Review-g187497-d630596-Reviews-Hesperia_Tower-Barcelona_Catalonia.html</p>
<p>Michelin * (or ** ??)</p>
<h2>Pretty Cool</h2>
<p>http://www.laparadeta.com/</p>
<p>make your order at the entrance &#8211; all &#8220;fish&#8221; &#8211; big portions &#8211; student restaurant </p>
<h2>Great value &#8211; nice ambiente</h2>
<p><a href="www.restaurantetrobador.com">www.restaurantetrobador.com</a><br />
Always a great value for the money and a nice and modern atmosphere, many locations city wide</p>
<p>www.flamantrestaurant.com</p>
<p>www.restaurantbalthazar.com </p>
<h2>Feelin&#8217; fishy?</h2>
<p>http://www.bcnrestaurantes.com/eng/barcelona.asp?restaurante=carballeria</p>
<p>close to port</p>
<p>http://www.botafumeiro.es/</p>
<p>probably one of the best fish restaurants in BCN &#8211; try the percebes ! </p>
<h2>Sea Views</h2>
<p>http://www.canmajo.es/ (views only from terrace) </p>
<p>http://www.aguadeltragaluz.com/</p>
<h2>Takin&#8217; a coffee in downtown</h2>
<p>www.4gats.com</p>
<p>http://www.bcnrestaurantes.com/barcelona.asp?restaurante=el-gran-cafe</p>
<h2>Rustic &#8211; outside BCN</h2>
<p>www.can-borell.com</p>
<h1>Day Trips</h1>
<p><a href="http://www.torres.es/esp/asp/index.asp">Torres</a><br />
Wine tasting outside of BCN</p>
<p><a href="http://www.freixenet.com/">Freixenet</a><br />
Cava &#8211; nice tour </p>
<p>http://www.barcelona-tourist-guide.com/en/tour/montserrat-spain.html &#8211; ca. 50km ausserhalb</p>
]]></content:encoded>
			<wfw:commentRss>http://blog.klaushofeditz.de/?feed=rss2&amp;p=261</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Estimating Project Costs</title>
		<link>http://blog.klaushofeditz.de/?p=254</link>
		<comments>http://blog.klaushofeditz.de/?p=254#comments</comments>
		<pubDate>Sun, 01 Nov 2009 20:08:31 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[]po[]]></category>
		<category><![CDATA[]po[ Development]]></category>

		<guid isPermaLink="false">http://blog.klaushofeditz.de/?p=254</guid>
		<description><![CDATA[This entry moved to http://www.project-open.org/documentation/rfe_Advanced_Financial_Project_Planning]]></description>
			<content:encoded><![CDATA[<p>This entry moved to <a href="http://www.project-open.org/documentation/rfe_Advanced_Financial_Project_Planning">http://www.project-open.org/documentation/rfe_Advanced_Financial_Project_Planning</a></p>
]]></content:encoded>
			<wfw:commentRss>http://blog.klaushofeditz.de/?feed=rss2&amp;p=254</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>How to prevent SQL Injections</title>
		<link>http://blog.klaushofeditz.de/?p=250</link>
		<comments>http://blog.klaushofeditz.de/?p=250#comments</comments>
		<pubDate>Sat, 17 Oct 2009 08:21:08 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[]po[ Development]]></category>
		<category><![CDATA[]po[ SysAdmin]]></category>

		<guid isPermaLink="false">http://blog.klaushofeditz.de/?p=250</guid>
		<description><![CDATA[http://stackoverflow.com/questions/1973/what-is-the-best-way-to-avoid-sql-injection-attacks Golden Rules: 3: Custom-Written Value Sanitation. Avoid writing your own sanitation routines as much as possible except when it&#8217;s absolutely the only option remaining (which is very unlikely in any modern language). Input sanitation is a hard problem, and the costs of getting it wrong are huge. It&#8217;s best to leave that job to [...]]]></description>
			<content:encoded><![CDATA[<p>http://stackoverflow.com/questions/1973/what-is-the-best-way-to-avoid-sql-injection-attacks</p>
<p>Golden Rules: </p>
<p>      3: Custom-Written Value Sanitation. Avoid writing your own sanitation routines as much as possible except when it&#8217;s absolutely the only option remaining (which is very unlikely in any modern language). Input sanitation is a hard problem, and the costs of getting it wrong are huge. It&#8217;s best to leave that job to someone else. When you are forced to rely on this method use white-listing rather than black-listing to sanitize input.</p>
<p>      2: Framework / Library Based Value Sanitation. Leave the sanitation routines to the domain experts. Sanitation routines in 1st party frameworks and libraries are typically created by the same folks that wrote the DB or the SQL API. They have a much higher chance of knowing, and properly handling, all of the edge cases than you do. An example of this technique would be using php&#8217;s mysql_escape_string() function to sanitize values that will be inserted into strings that serve as dynamic SQL statements.</p>
<p>      1: Parameter Binding. Instead of constructing a SQL statement as a raw string which includes user data as in-place literal values, create a SQL statement with tokens where the user data would be. Then bind the user supplied data to the appropriate parameters. The key here is that this binds the provided data to a specific type and a specific use and eliminates any opportunity to change the logic of the SQL statement. This can be used in conjunction with library based input sanitation as well.</p>
<p>http://www.tcl.tk/community/tcl2004/Tcl2003papers/cleverly.htm</p>
<p>Luckily for the Tcl programmer who craves laziness, OpenACS provides a higher-level database API on top of ns_db that hides all the mundane house-keeping chores. Additionaly, bind-variable emulation is available which frees the programmer from worrying about always escaping apostrophes in SQL statements. Bind variables are prefaced with a colon.</p>
<pre>
 set name "Jim O'Connor"
            set salary 40000

            db_dml new_hire {
                insert into employees (name, salary, dept)
                values (:name, :salary, 'Accounting')
            }
</pre>
<p>http://openacs.com/forums/message-view?message_id=250625</p>
<p>Posted by Dave Bauer on 01/19/05 04:57 PM</p>
<p>In Postgresql the db_* commands extract the &#8220;bind&#8221; variables and SQL quote them automatically. In the PG driver itself the [] charactaers are escaped as well for safety.</p>
<p>This means that the effective security of PostgreSQL is the same as Oracle.</p>
<p>This is done at the database api layer.</p>
<p>In addition ad_page_contract has filters and validation features to check input. ad_form and the form builder also have validation features for input.</p>
]]></content:encoded>
			<wfw:commentRss>http://blog.klaushofeditz.de/?feed=rss2&amp;p=250</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>XOWIKI &#8211; db structure</title>
		<link>http://blog.klaushofeditz.de/?p=249</link>
		<comments>http://blog.klaushofeditz.de/?p=249#comments</comments>
		<pubDate>Mon, 12 Oct 2009 07:47:39 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[]po[ Data Modell]]></category>
		<category><![CDATA[]po[ Development]]></category>

		<guid isPermaLink="false">http://blog.klaushofeditz.de/?p=249</guid>
		<description><![CDATA[xowiki pages are managed with the OpenACS Content repository. XOWIKI pages: For each page there&#8217;s an entry in cr_items projop=# \d cr_items Table "public.cr_items" Column &#124; Type &#124; Modifiers -------------------+------------------------+------------------------------------------------ item_id &#124; integer &#124; not null parent_id &#124; integer &#124; not null name &#124; character varying(400) &#124; not null locale &#124; character varying(4) &#124; live_revision [...]]]></description>
			<content:encoded><![CDATA[<p>xowiki pages are managed with the OpenACS Content repository. </p>
<h2>XOWIKI pages:</h2>
<p>For each page there&#8217;s an entry in  <em>cr_items</em></p>
<pre>
projop=# \d cr_items
                                   Table "public.cr_items"
      Column       |          Type          |                   Modifiers
-------------------+------------------------+------------------------------------------------
 item_id           | integer                | not null
 parent_id         | integer                | not null
 name              | character varying(400) | not null
 locale            | character varying(4)   |
 live_revision     | integer                |
 latest_revision   | integer                |
 publish_status    | character varying(40)  |
 content_type      | character varying(100) |
 storage_type      | character varying(10)  | not null default 'text'::character varying
 storage_area_key  | character varying(100) | not null default 'CR_FILES'::character varying
 tree_sortkey      | bit varying            | not null
 max_child_sortkey | bit varying            |
</pre>
<h2>Page content</h2>
<p>Page content is stored in table <em>cr_revisions</em></p>
<pre>
projop=# \d cr_revisions
                             Table "public.cr_revisions"
     Column     |           Type           |                Modifiers
----------------+--------------------------+-----------------------------------------
 revision_id    | integer                  | not null
 item_id        | integer                  | not null
 title          | character varying(1000)  |
 description    | text                     |
 publish_date   | timestamp with time zone |
 mime_type      | character varying(200)   | default 'text/plain'::character varying
 nls_language   | character varying(50)    |
 lob            | integer                  |
 content        | text                     |
 content_length | integer                  |
</pre>
<h2>Finding content that can&#8217;t be found using &#8216;search&#8217; such as links etc.</h2>
<pre>
select
		r.item_id,
		r.title,
		i.name
from
		cr_revisions r,
		cr_items i
where
		r.content like '%en:install_main%' and
		r.revision_id = i.live_revision;
</pre>
<h2>Object Model</h2>
<p>Pls. see: <a href="http://openacs.org/xotcl/show-object?show_source=0&#038;object=%3A%3Axowiki%3A%3APage&#038;show_methods=1">http://openacs.org/xotcl/show-object?show_source=0&#038;object=%3A%3Axowiki%3A%3APage&#038;show_methods=1</a></p>
]]></content:encoded>
			<wfw:commentRss>http://blog.klaushofeditz.de/?feed=rss2&amp;p=249</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
