Back to the month index |
Back to the list index
|
Henry Minsky (hqm@ua.com)
Sun, 1 Sep 1996 16:08:15 -0700
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
- Next message: Jeff Lee: "Re: [mSQL] Chat Rooms"
- Previous message: Craig Hoskin: "Re: [mSQL] Opinions? Best msql web interface"
- Maybe in reply to: Larry Steinberg: "[mSQL] Opinions? Best msql web interface"
- Next in thread: Andreas Rittershofer: "Re: [mSQL] Opinions? Best msql web interface"
Date: Sun, 1 Sep 1996 16:08:15 -0700 From: Henry Minsky <hqm@ua.com> Message-Id: <199609012308.QAA18354@merlin.datawave.net> Subject: Re: [mSQL] Opinions? Best msql web interfaceHi all,
Subject says it all. For a URL database(s) with
Category,Title,URL,Description,Name,Email fields. Currently about 20,000
records.
TIA,
Larry
Well, since you asked ...
We have a new product called Meta-HTML, for which I wrote the MSQL
interface. Meta-HTML is a web scripting and application development
system based on a powerful macro programming language which has HTML
syntax.
o Meta-HTML has a great MSQL-to-Web interface. Below is an example
from an accounts database application.
o Meta-HTML is run on the server as a pre-processor for your web
pages. It evaluates down to HTML and also has side effects, like
operating on the MSQL database.
o You can find out more about Meta-HTML at http://www.metahtml.com.
o We will be releasing a *free-software* version of Meta-HTML on
Sep. 15th (with full source code!), and will be doing a commercial
version which has a MSQL and ODBC interface module to it, which can
connect to an existing MSQL database. The commercial version with MSQL
is scheduled for Oct 15, but Beta copies may be available by
arrangement.
o The free version of Meta-HTML comes with a built in GDBM database,
but does not have the MSQL interface module.
================================================================
Below is the code for a web page which both presents a form for
querying the user database, and also handles the posted data and does
the query, and formats the result as a table:
;;; Present a form to the user, to select a range of UIDs from
;;; the accounts database
<form action=<get-var mhtml::location> method=post>
Start UID: <input type=text name=uid-lower maxlength=12 size=12>
Number of records: <input type=text name=num-records maxlength=12 size=12>
</pre>
<input type=submit name=action value=SUBMIT>
</form>
;;; If the variable posted::action is set, it means this
;;; page was posted to.
<when <and <get-var posted::action> <get-var uid-lower>>>
;;; Display a maximum of 100 records
<if <not <get-var num-records>> <set-var num-records=1>>
<if <gt num-records 100> <set-var num-records=100>>
<set-var uid-upper=<add uid-lower num-records>>
<h3>Listing UIDs from <get-var uid-lower> to <get-var uid-upper>:</h3>
<set-var q-list-users=>
<msql::with-open-database mydb database=corporate host=localhost>
<table border=1>
<tr><th>uid</th>
<th>uname</th>
<th>pin</th>
</tr>
<msql::database-query mydb true
query="SELECT * FROM accounts WHERE
uid >= '<get-var uid-lower>'
AND uid < '<get-var uid-upper>'"
format=
<prog
<tr>
<td><get-var uid></td>
<td><get-var uname></td>
<td><get-var pin></td>
</tr>
>>
</table>
</msql::with-open-database>
This returns an HTML table of output records.
================================================================
That's all there is to it. Its a very powerful system, because it uses
macro substitution on the source HTML, so you can intermix SQL and
Meta-HTML and HTML freely, in a very compact way.
Meta-HTML also features
o Variables and Flow Control Statements
o Relational Operators
o Arithmetic Operators
o Package Operations
o File inclusion and HTTP Redirects
o Comments and Block Quoting
o Character Manipulation
o String Manipulation
o Powerful Regular Expression Operations
o Page Wide Manipulation
o Streams and Files
o Sessions and Persistent Variables
o Database Access
o User Defined Commands
I wrote the free-software WebSQL-MSQL browser
(http://www.ua.com/websql) using the C API, and after that experience,
I can tell you that using Meta-HTML will save approximately 99% of the
time needed to write a Web->MSQL application!
If you have any questions, send me a note.
Thanks,
Henry Minsky
Universal Access Inc
129 El Paseo
Santa Barbara CA 93101
v 805.730.7775
f 805.730.7776
email: hqm@ua.com
--------------------------------------------------------------------------
To remove yourself from the Mini SQL mailing list send a message containing
"unsubscribe" to "unsubscribe" to msql-list-request@bunyip.com. Send a message containing
"info msql-list" to majordomo@bunyip.com for info on monthly archives of
the list. For more help, mail owner-msql-list@bunyip.com NOT the msql-list!
- Next message: Jeff Lee: "Re: [mSQL] Chat Rooms"
- Previous message: Craig Hoskin: "Re: [mSQL] Opinions? Best msql web interface"
- Maybe in reply to: Larry Steinberg: "[mSQL] Opinions? Best msql web interface"
- Next in thread: Andreas Rittershofer: "Re: [mSQL] Opinions? Best msql web interface"