Received: from localhost (maia-1.hub.org [200.46.204.191]) by postgresql.org (Postfix) with ESMTP id 951A09FB8B0 for ; Thu, 26 Apr 2007 07:28:16 -0300 (ADT) Received: from postgresql.org ([200.46.204.71]) by localhost (mx1.hub.org [200.46.204.191]) (amavisd-maia, port 10024) with ESMTP id 36880-08 for ; Thu, 26 Apr 2007 07:28:12 -0300 (ADT) X-Greylist: from auto-whitelisted by SQLgrey-1.7.4 Received: from smtp1.yandex.ru (smtp1.yandex.ru [213.180.223.87]) by postgresql.org (Postfix) with ESMTP id B84DE9FB7FD for ; Thu, 26 Apr 2007 07:28:11 -0300 (ADT) Received: from [82.209.238.118] ([82.209.238.118]:17420 "EHLO asup_tur" smtp-auth: "sql4-en" TLS-CIPHER: TLS-PEER-CN1: ) by mail.yandex.ru with ESMTP id S2077325AbXDZK1w (ORCPT ); Thu, 26 Apr 2007 14:27:52 +0400 X-Comment: RFC 2476 MSA function at smtp1.yandex.ru logged sender identity as: sql4-en Date: Thu, 26 Apr 2007 13:27:54 +0300 From: Dmitry Turin X-Mailer: The Bat! (v2.01) Personal Reply-To: Dmitry Turin X-Priority: 3 (Normal) Message-ID: <13119753000.20070426132754@narod.ru> To: pgsql-sql@postgresql.org Subject: Re: Fwd: Re[2]: We all are looped on Internet: request + transport = invariant In-Reply-To: <46306668.10506@archonet.com> References: <14110647859.20070413105812@narod.ru> <20070413150936.GA31517@phlogiston.dyndns.org> <1684192906.20070419090827@narod.ru> <20070419134808.GB14187@phlogiston.dyndns.org> <814860828.20070420120819@narod.ru> <4628A08F.9050804@archonet.com> <1177072978.760.40.camel@pampa> <7939450187.20070420185808@narod.ru> <1177095450.760.71.camel@pampa> <1312216062.20070423112045@narod.ru> <1177329421.737.39.camel@pampa> <3817356375.20070424150200@narod.ru> <462DFAD4.7030001@archonet.com> <3512994062.20070425113253@narod.ru> <462F1781.4070501@archonet.com> <4412563734.20070426112805@narod.ru> <46306668.10506@archonet.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=1.055 tagged_above=0 required=5 tests=AWL=0.156, BAYES_20=-0.74, URIBL_SBL=1.639 X-Spam-Level: * X-Archive-Number: 200704/264 X-Sequence-Number: 28264 Good day, Richard. >> RH> >> RH> >> RH> >> RH> These three flights represent options >> RH> >> RH> >> RH> RH> 1. A journey (flight_chain) between city A and city Z consists of one or RH> more flights. RH> 2. The next flight has to start at the current city, but there may be RH> several flights to choose from. RH> 3. The last flight must end at city Z. RH> Now stage 2 groups the flights to choose among - you can call it RH> something else, but the equivalent of flight_options is there. Tag "city" executed the same role in my version, that tag "flight_chain" in your version. >> RH> 2. If you nest flights then you'll be forced to repeat data, surely? >> RH> Multiple routes could end up mentioning flight id=123 several times and >> RH> each time have to repeat all possible options from it. >> >> Yes. >> Remember, this is not manner of storing data in DBMS. >> This is manner to visualize for man. RH> So how do I know it's repeated without grabbing a pencil and paper and RH> scrolling back and fore to compare them? Write XML-form, which illustrate, what are you want. I will write request. RH> Are you sure this wouldn't just be easier if you wrote a specialised RH> data-visualiser application? Avarage used can not use library of intermediate language to join DBMS and browser. P.S. Programmers are small percent of all users. >> RH> If I'm going to learn only one query language, it'll be SQL >> RH> because everything uses it. >> >> 'tablename >>;' is better, than to learn php, perl, its library RH> But you're not doing the same thing. I'm not doing? I have write example! >> Term "scheme" means "database scheme" to me :) RH> But you were talking about XML at the time. XML is not stored thing, it is a transport form for scheme. Let's ask concrete questions, ok? >> RH> I'm sat here at my laptop, and I want to get a >> RH> list of flights into a spreadsheet I'm doing for my boss. >> >> Your boss will itself solve "task of travelling-salesman" ? >> By eyes ? RH> No, but my boss wants a list of flights from London to Madrid for next RH> Friday, with prices, times etc. Direct flight? #city[name="London"].flight/c1:c2[#c1 #c2 #day="friday"].#city[name="Madrid"] >>; Roundabout flight? #city[name="London"].(flight/c1:c2[#day="friday" t1-^^.t2>30min].city)*||name="Madrid" ; Prices and times is attributes of FLIGHT. These are in Example 2. http://sql4.by.ru/site/sql40/en/author/wave_eng.htm RH> So what does it matter to me as a user User only use. Difference between realizations of site is important only for authors of site. RH> whether the site is written in TML+Java What will Java do ? RH> And if I'm building the site in PHP anyway (and I'm going to need RH> forms/buttons/etc in some language) then what am I gaining from the TML? >> create view x as >> select city.name as start, city.name as end, flight.t1, flight.t2, day >> from city, flight; >> x >>; RH> Hang on - you're using SQL. Why not just use pgadmin and paste the RH> results from my query if I'm using SQL anyway? paste by hands? RH> Sorry - you didn't eliminate any code there. I simplify code. Compare call of php library for database, getting record set, embrace records in circle by html-tags, call php library for http-communication. RH> But the transport of the data is trivial, assuming I have a webserver RH> and PHP/Perl/ASP/etc. available. 1. Speak not about you, but about average user. You don't know real statistics. 2. Even you make superfluous job. Dmitry Turin http://html6.by.ru http://sql4.by.ru http://computer2.by.ru