HDTenEightyP/NetNews huggingface dataset:
From: jjm+@andrew.cmu.edu (James J. Murawski)
Newsgroups: comp.databases.ingres
Subject: Re: Q: nested group by
Date: 21 Jul 92 04:00:36 GMT
Article-I.D.: andrew.QeOzlYi00Uh7M1838Q
Organization: Administrative Systems, Carnegie Mellon, Pittsburgh, PA


On 20-Jul-92 in Q: nested group by           
user Stephan Ozminski@pucc.Pr writes:
>Does anyone know about the following bug?  I ask on the net because we
>do not have Technical Support, only Update Support, so I am not likely
>get a response if I sent them a message directly.  So, I'm posting to
>the net without first asking Ingres.
>
>It is possible for Ingres (SunOS v6.3 and v6.4/01) to return incorrect
>results if a view with a group by clause references a view with a
>group by clause, even though relational theory would dictate
>otherwise.
> 
>Nested group by clauses are necessary because Ingres SQL does not
>support nested aggregate functions.  Of course the alternative is to
>create intermediate tables, but I should have to do that.  I don't
>like having to remember to delete junk tables.
> 
>Here is an example of nested group by clauses:
> 
>create view tagcountv as
>select id, subentry, tag, count(tag) as tagcount
>from datatable
>GROUP BY ID, SUBENTRY, TAG;
> 
>create view tag_max as
>select tag, max(tagcount) as maxcount
>from tagcountv
>GROUP BY TAG;
>
>When I select from tag_max, I get repeats of several of the tags, with
>different maximum counts.
> 
>If I change tagcountv to have a group by clause of:
> 
>        GROUP BY TAG, ID, SUBENTRY
> 
>Then the aggregates are calculated properly.  Presumably, the problem
>is caused by Ingres not sorting the table resulting from tagcountv,
>before it calculates aggregates for tag_max.  Is this a general
>problem with SQL implementations or just an Ingres bug?

I definitely came across this problem in Ingres 6.3/01 (sqs.us5/01).
If I remember correctly, a techincal contact here said that Ingres
acknowledged it as a bug.

====================================================================
    Jim Murawski
    Sr. Data Base Analyst               (412) 268-2650  [office]
    Administrative Systems              (412) 268-6868  [fax]
    Carnegie Mellon University          jjm+@andrew.cmu.edu
    4910 Forbes Avenue                  Office: UCC 155
    Pittsburgh, PA 15213-3890
From: hevern@janis.cac.washington.edu (Michael Hevern)
Newsgroups: comp.databases.ingres
Subject: Re: vision application defaults
Date: 24 Jul 92 18:58:52 GMT
Article-I.D.: u.1992Jul24.185852.10166
Organization: UW Information Systems

In article <BruG02.9sH@news.udel.edu>, bouton@gertrude.cms.udel.edu (Katherine Bouton) writes:
> We are developing an application in VISION and want to rename the keys e.g >TopFrame=MainMenu.
> How do we do this for the whole application at once without going into each >osq?
> Also... how do we make List Choices menu item come up on a frame ONLY when >there is
> a list choices option? I hate hiting listChoices to get that error message - >sorry, no list choices,
> field-c20 etc...
> thanks
> Katherine
> 

Myrecomendation for the list choices is a post parser that goes into the catalogs ans checks the visualquery. Ifa listchoices "link" is present leave the file alone,otherwise make a new copy of the file excluding the list choices option (parse it out).
 
Good luck,
-- 	MH
       *--------------------------------*------------------------------*
       | Michael Hevern			| Voice: (206) 685-3229        |
       | University Of Washington	| * "I can't dance...          |
       | Information Systems		|    I can't talk...           |
       | 4545 15th Ave. NE		|    The only funny thing about|
       | Seattle, WA 98105		|    me is the way I walk."    |
       | Mail Stop: JE-41               |       -- Genesis             |
       *--------------------------------*------------------------------*
	Disclaimer: If I said it I probably meant it.  My employer isn't
		responsible for my opinions.
Newsgroups: comp.databases.ingres
From: sethg@dcatlas.dot.gov (Seth Grimes)
Subject: Re: Natural Language users?
Organization: U.S Dept. of Transportation
Date: Thu, 23 Jul 1992 12:09:55 GMT


Sorry, the product we (for Federal Aviation Administration) are using is
called Natural Language, and it come from a company called Natural
Language Inc., 1-800-NLI-5858.  It runs on VMS and various Unix platforms,
with "Windows 3.2 (1992)" listed in their brochure, against all the major
commercial RDBMSes.  It runs under various X or in character-cell mode,
so if you run an X server on your PC, you can run pseudo-client-server.
I say pseudo because the NLI front-end would still be running on the 
X client, not on your PC, which is the X server.  (Got it?)  I don't 
know, maybe if you're running Unix on your PC -- the brochure lists
Intel 386 & 486 for platforms -- you can run true PC->other client-
server.

This is a commercial product, and it's expensive.  I think it cost us
around $25k (GSA price) for our DECSystem 5100.  I think you can buy
run-time licenses (i.e., not developer) for less.

To use this thing, you have to create a dictionary/thesaurus and a grammar
book, which can be a lot of work.  I would guess that developers in the
NL field are working on applying neural nets in a learn-by-example
environment, but that's not here yet commercially.

			Seth
From: "james syniura" <james.syniura@canrem.com>
Newsgroups: comp.databases.ingres
Subject: passing table field r
Date: 30 Jul 92 14:47:37 EST
Reply-To: "james syniura" <james.syniura@canrem.com>
Distribution: comp
Organization: Canada Remote Systems


WJ>We are running INGRES 6.4 on a Sun.  I have a tablefield defined in an
WJ>ABF application frame which I pass to another frame like this:
WJ> callframe modproc (modproc := emptable.all);
WJ>Emptable has two fields, empnum and empname.  The called frame
WJ>"modproc" has two simple fields also called empnum and empname.  I
WJ>would like the user to simply be able to change those fields.  However,
WJ>if the fields are changed, when the user returns to the calling frame,
WJ>the table fields HAVE NOT CHANGED.  I can't figure out what I'm doing
WJ>wrong.  The manual says that I'm passing the table field row by
WJ>reference, so you'd think that it would be changed.

WJ>What gives here?  Please E-mail me directly; I'm not on this list.

Since I can't E-mail you directly, maybe this will make it's way to you.

Try sending the table row by reference, in other words use
callframe xxxx (  table.name = byref(table.name));


----------------------------
Bell Canada - System Support

James Syniura
---
  DeLuxe/386 1.12 #6442  Captain, please not in front of the Klingons!
--
Canada Remote Systems  - Toronto, Ontario/Detroit, MI
World's Largest PCBOARD System - 416-629-7000/629-7044
Newsgroups: comp.databases.ingres
From: cs_mj@gsbacd.uchicago.edu (Mark Jaeger)
Subject: Re: Knowledge Management Product       
Organization: 
Distribution: usa
Date: Tue, 21 Jul 1992 05:28:59 GMT

In article <1992Jul17.194315.17770@advtech.uswest.com>, joe@maverick 
(Joe Thielan) writes:
> I have a basic question about the Knowledge Management Product.
> 
> 1)  If you create a table, and on field1 in that table, you use the 
>     'not null not default' option.  
> 
> 2)  Then you create a rule for that table for inserts & updates.   
> 
> 3)  Then you issue an SQL command to insert a record into the table and
>     field 1 is null.
> 
> What happens?
> 
> 1)  Does the rule get executed, and then the database sees that field1 is null,
>     and errors out?
> 
> 		--  or --
> 
> 2)  Does the database first check to see if field1 is null and if it is, errors
>     out?  and if field1 isn't null, it executes the rule?

It's number 2.  I don't know that much about server internals,
especially when it comes to rules, but I think that they get triggered
in QEF, when the query is actually getting executed.  I'll bet that the
error you trigger by inserting a null into a column that won't accept
it is found in PSF, the parser.  

Here's how I tested it:

1.	create table t ( id i4 not null ) ;
2.	create procedure p = { message 'hello' ; } ;
3.	create rule r after insert into t execute procedure p ;

4.	set printrules ;
5.	insert into t values ( 17 ) ;
6.	insert into t values ( null ) ;

7.	set optimizeonly ;
8.	insert into t values ( 17 ) ;
9.	insert into t values ( null ) ;

(4) is a handy debugging tool that lets you see what's going on.  (5)
succeeds, and (6) fails, and we get to see that the rule does _not_
fire.  (7) makes the server stop processing after PSF and OPF, but
before QEF.  We don't see the rule fire in (8), which is what makes me
think that rules are fired by QEF.  We still see the error in (9), which
is what makes me think that PSF catches the incompatibility error.

--Mark Jaeger				internet: cs_mj@gsbvax.uchicago.edu
Graduate School of Business		yellnet:  (312) 702-0328
University of Chicago			faxnet:   (312) 702-0233
Disclaimer: My opinions are my own and not those of my employer.
Ich bin ein Virus.  Mach' mit und kopiere mich in Deine .signature.

Newsgroups: comp.databases.ingres
From: drcoles@somnet.sandia.gov (Dwight R Coles)
Subject: Re: Creating Table Fields on the Fly
Organization: National Radio Astronomy Observatory
Date: Fri, 24 Jul 1992 20:17:38 GMT

> In article <1992Jun15.141818.18709@schaefer.math.wisc.edu>, 
> horn@schaefer.math.wisc.edu (Jeffrey Horn) writes:
> > Would anybody out there have an example of how one might create table
> > fields on a ingres form on the fly.  What I want is an example of how
> > a QBF retrieve is actually programmed in embedded SQL or in ABF/4GL.
> > That is, first look up the definition of a database table, then create
> > a table on a form with appropriate columns, then fill the table.  What
> > I can't figure out how to do is the creation of a table field on the
> > fly!
> 
> My only suggestion (and it's a kluge) is to reverse engineer the system
> catalogs that hold forms--ii_objects, ii_forms, ii_fields, ii_trim, and
> maybe ii_encoded_forms.  A form is nothing more than a bunch of entries
> in these tables, and a table field in particular is a bunch of entries
> in the ii_fields system catalog.
> 
> This is dangerous because they can change at any time the system
> catalogs that hold front-end objects (but not the Standard Catalog
> Interface to back-end objects, except for adding new columns), but you
> might be able to use it in a pinch.  Also, an application that did this
> would have to connect to the database as the dba, or with a special
> flag, like "+U".  This would certainly limit its utility.
> 
> --Mark Jaeger		internet: cs_mj@gsbvax.uchicago.edu

Well, folks, this can and has been done.  I developed what I called
programmable-qbf about three years ago, using exactly what Mark 
alluded to - reverse engineer the forms-definition system catalogs.
Then you 1) read the data-definition system catalogs
	 2) determine what the form needs to look like
	 3) write to the forms-definition catalogs
	 4) run the application code which uses the form (although,
	    sigh, I never figured out a way to compile the form
	    and dynamically link it into the running application).
If you are REALLY interested in following the same path and are willing
to update the code to run with V6 catalogs, and translate it from
QUEL to SQL (it is in parameterized QUEL, and will probably need 
dynamic SQL), then drop me a note and we'll talk.  It took about
a month the first time, so I won't do it myself again unless forced.

Dwight   drcoles@sandia.gov

and oh by the way, I didn't have to use a special connect privilege -
you can write to the forms definition catalogs without it, as I recall.
Newsgroups: comp.databases.ingres
From: alan@curta.cc.columbia.edu (Alan Crosswell)
Subject: Re: select * with a 3-way join having same column names in ESQL/C
Organization: Columbia University
Date: Wed, 29 Jul 1992 17:04:45 GMT

In article <1992Jul29.092836.27821@walter.cray.com> djm@dagmar.cray.com  
(Dave Miller) writes:
> 
> In article <1992Jul29.000202.23983@news.columbia.edu>,  
alan@curta.cc.columbia.edu (Alan Crosswell) writes:
> 
> In the fetch, you are just retrieving into the three columns specified.   
Again
> this is perfectly legal, since it is allowable to have more columns that  
are
> selected than are retrieved into.  The extra columns are just skipped.
> At runtime, there might be some type conversion problems (as you noted)  
that
> would result in errors.  The runtime routines do the best job they can  
of doing
> the conversion.  If the "hosts" table has 3 or more columns, all of your  
result
> rows would be from that table, probably not what you intended.
> 
> Dave Miller
> Cray Research, Inc.
> EXEC SQL include <std.disclaimer>

Dave, the fetch is into three *structs*, not three variables.  So,
the fetch *should* expand into the same number of columns as the
select does.

However, kudos to Chris Amidei who teaches Ingres for ASK/Ingres for
suggesting this which seems to work right:

    exec sql declare x cursor for
              select h.*, hw.*, i.*
                from hosts h, hwaddr hw, ip i
               where h.hname = i.hname
                 and i.ipaddr = hw.ipaddr;

I can now go back to fetching into :hosts, :hwaddr, :ip!

/a
PS: For further edification, the structs generated by dclgen are:

/* Description of table ip from database network */
  EXEC SQL DECLARE ip TABLE
        (hname  vchar(50) not null,
         ipaddr vchar(15) not null,
         ipcolate       integer1 not null);

  struct ip_ {
        char    hname[51];
        char    ipaddr[16];
        short   ipcolate;
  } ip;

/* Description of table hwaddr from database network */
  EXEC SQL DECLARE hwaddr TABLE
        (ipaddr vchar(15) not null,
         type   vchar(10) not null,
         hwaddr vchar(12) not null);

  struct hwaddr_ {
        char    ipaddr[16];
        char    type[11];
        char    hwaddr[13];
  } hwaddr;

/* Description of table hosts from database network */
  EXEC SQL DECLARE hosts TABLE
        (hname  vchar(50) not null,
         htype  vchar(15) not null,
         hos    vchar(15) not null,
         hdept  vchar(10) not null,
         hreg   c8 not null);

  struct hosts_ {
        char    hname[51];
        char    htype[16];
        char    hos[16];
        char    hdept[11];
        char    hreg[9];
  } hosts;

(Another dclgen/ESQL plug: it has enabled me to stop using that awful OSL
 language since the one nice thing it did for me was allow me not to have
 to enumerate all the columns as I did in my EQUEL/C retrieve statements.)
From: cs_mj@gsbacd.uchicago.edu (Mark Jaeger)
Newsgroups: comp.databases.ingres
Subject: Re: INGRES ReportWriter Woes
Date: 23 Jul 92 20:45:27 GMT

In article <1992Jul21.225744.26654@mprgate.mpr.ca>, sandie@mprgate.mpr.ca
(Bert Sandie) writes:
> ...report writer problem...
> ...only one query, no outer join in INGRES...
>
> I have used UNIONS in the past to simulate an outer join, but,
> when more than 1 case of an outer join is needed in a single
> query (ie more than 1 UNION) then the performance of the
> query is degraded rapidly.  In 4GL the problem of outer joins
> can be fixed by using multiple queries with conditional
> statements which check for the possible existance of an outer
> join and thus prohibit a select statement from returning
> nothing because of an outer join NULL match is found.

As Gavin Trigg pointed out, you can use .SETUP and .CLEANUP to work
around these limitations.  Here's an example:

	.name my_report

	.setup
		create table temp_table as
			select m.* , detail1_x = -17 , detail2_y = -17
			from my_master m where ... ;

		update my_master m from my_detail1 d
			set detail1_x = d.x where d.id = m.id ;

		update my_master m from my_detail2 d
			set detail2_y = d.y where d.id = m.id ;

	.cleanup
		drop table temp_table ;

	.query select * from temp_table ...

This works in INGRES even if you have outer join problems.  The first
select makes sure that you get all the rows you want from the original
table.

The update takes care of filling in the detail data, but it only changes
it for the master rows where there _is_ a detail record.  The first
select sets the detail columns to some special value (-17, in this case)
so that you can recognize it later as a value where the detail is
missing.  You could use nulls, too, but I don't happen to like them.

As you can see, you can use as many different detail relationships as
you like.

There are lots of refinements to be made.  You may have to worry about
locking, so you may want to put "commit;" statements in there.  You
might want to index the temporary table so the joins are more efficient.  

Hope this helps.

--Mark Jaeger				internet: cs_mj@gsbvax.uchicago.edu
Graduate School of Business		yellnet:  (312) 702-0328
University of Chicago			faxnet:   (312) 702-0233
Disclaimer: My opinions are my own and not those of my employer.
Ich bin ein Virus.  Mach' mit und kopiere mich in Deine .signature.
Newsgroups: comp.databases
From: neuwirth@ferranti.com (howard neuwirth-hirsch)
Subject: Re: Upgrading Paradox
Organization: Ferranti International Controls Corporation
Date: Fri, 24 Jul 1992 22:05:39 GMT

In article <Jul.22.17.44.33.1992.5398@dimacs.rutgers.edu>, magarell@dimacs.rutgers.edu (Christopher Magarelli) writes:
> 
>      Could somebody tell me what, if any, conversion of files is
> necessary when upgrading from Paradox 3.01a to 3.5?     I'd appreciate
> any help.
> 
>           Chris Magarelli

No conversion is needed.

H.

-- 
Howard Neuwirth-Hirsch

neuwirth@ficc.ferranti.com
Newsgroups: comp.databases
From: matthewp@ruby.aruba.UUCP (Matthew Pope)
Subject: Windows NT, ODBC, DB-Library info.
Date: Thu, 23 Jul 1992 21:42:21 GMT
Organization: Project Zed
Keywords: ODBC DB Windows NT

Hello database folk, I am researching Windows NT database support:
1)  Any idea which RDBMS vendors have committed to or delivered in terms of support for Windows NT ODBC API?
2)  I understand DB-Library is Microsoft's interim DB API, does it support ANSI 
standard 1989 (X3.135) SQL?
3)  Will existing DOS based embedded 'C' precompilers work under NT?
 
-----------------------------------------------------------------------------
Matthew Pope                 |  Internet Style: aruba!matthewp@uu2.psi.com
Project Zed                  |  UUCP   : ...!uunet!uu2.psi.com!aruba!matthewp
AEAU - Against Extraneous Acronym Usage      "Make Love Not War"  
-----------------------------------------------------------------------------
From: lindsey@tincup.enet.dec.com (Randy Lindsey)
Newsgroups: comp.databases
Subject: Re: FoxPro questions, 2 easy, 1 harder.. : )
Date: 30 Jul 92 23:07:18 GMT
Organization: Colorado Software Solutions, Inc.


In article <1992Jul25.154312.1@acad3.alaska.edu>, fscll@acad3.alaska.edu (Christopher Lee Lott -- One foot in the grave and the other slipping) writes...
>1) Is there anyway to check for duplicate records using asingle field as the
>key that is as easy as marking the field a key when you create it (I am told
>you can do this in paradox)? I am trying to avoid having to scan the whole
>database as I enter each record...

I'm not sure what's wrong with the solution you suggest.  Just make the 
single field a key, NODUPLICATES, then either let Foxpro tell you it's an
error when you attempt to add the record, or program it to seek on that
key first yourself.  You can add new keys (TAGs in a structural compact
index file are best) any time.

>2) Is there any way to avoid blank lines when doing mailing labels and having
>an empty field sometimes?

I think the Foxpro label generator does this automatically.  Anyone else
know if I'm wrong?

>3) Is there a way to transfer a data set from Quattro (as SDF is fine) into
>FoxPro, and then have go through the database and add up the occurrences of
>the same name? I have a large database of orders with the structure:
> 
>Order Number    Name               etc..
>124234234       Doe, John
>1334534         Doe, Jane
>12354345        Doe, John
> 
>and I want to count up how many orders each person has... I figured some way
>of sorting the database, finding the first occurrence, counting, finding next,
>etc. I want to be able to do this without having to manually key in each name,
>so when new customers come in they automatically get added... 
>(this one may not be so easy, but any and all help is appreciated)

If you have an index on name, with duplicates allowed, you can just do
a scan (either with or without the SCAN statement), counting up the occurances
and writing the count to wherever.  You might also be able to do it with
nested SELECT's (SQL), but I'm not an SQL wizard yet.

Randy
From: biwine@vaxsar.vassar.edu
Newsgroups: comp.databases
Subject: TPC benchmark info wanted
Date: 23 Jul 92 13:24:55 +1000
Organization: Vassar College

Can someone direct me to a source of TPC benchmarks for 
various hardware platforms?

Thanks for your help.

Bill Wine
System Manager
Vassar College
biwine@vassar.edu
Newsgroups: comp.databases
From: leary@progress.COM (James Leary)
Subject: Re: Progress Info Wanted
Organization: Progress Software Corp.
Date: Thu, 23 Jul 1992 16:45:33 GMT

howard@homebase.vistachrome.com (Howard Kennedy) writes:

>	We are currently using Oracle.  We are considering using Progress at least
>	for one of our projects.  We need information and opions about the
>	following products:

>	Progress 4GL.
>	Progress First Track.
>	Progress Results.
>	Progress Fast Attack.

>	We would also like to hear from sites that have converted from
>	Oracle to Progress.

The products you are inquiring about are:

Progress 4GL.
Progress Fast Track
Progress Results.

If you would like further information regarding our products, please call 
1-800-327-8445.

Thanks for your interest.
From: rjmartin@extro.ucc.su.OZ.AU (Trilogy Business Systems)
Newsgroups: comp.databases
Subject: Sybase rounding problem
Summary: We need to get sybase to round money fields to 2 decimal places
Keywords: Sybase Rounding
Date: 22 Jul 92 00:48:43 GMT
Organization: Sydney University Computing Service, Sydney, NSW, Australia

We have an stockbroking application that uses Uniface as the front end, and
Sybase as the back end. Uniface keeps money fields to 2 decimal places, and 
performs all calculations based on that assumption. Sybase on the other hand
keeps money fields to four decimal places and calcuation are to that precision.
This is causing us ** MAJOR ** problems, especially when balancing accounts,
and closing open contracts etc.

Does anybody know of a way to force Sybase to round money fields to 2 decimal
places e.g.

	123.4549 --> 123.45
	123.4550 --> 123.46

Any help will be greatly appreciated, Please mail, and I will post a summary.

Yours Faithfully


John Martin
Software Manager
Trilogy Business Systems Pty Ltd. (Aust)
Newsgroups: comp.databases
From: koops@asterix.gaul.csd.uwo.ca (Luke Koops)
Subject: Report writer needed for FoxPro 1.02 application
Reply-To: koops@asterix.gaul.csd.uwo.ca (Luke Koops)
Organization: University of Western Ontario
Date: Tue, 28 Jul 1992 19:13:41 GMT
Keywords: foxpro, report writer


At the company where I work, we are looking for a report writer to use with a
FoxPro 1.02-deleloped system.  We don't want to use the FoxPro developer's kit
report writer, because it is bundled with the whole development environment --
we don't want to give our users write acess to the system's databases.

Does anyone know if such products are available?  If you've used one, or
several, please tell me (through email) your likes/dislikes, and the name(s)
and manufacturers of the product(s).

Thanks very much.

...Steve van der Burg
koops@obelix.gaul.csd.uwo.ca
(using a friend's account)
 
*****
*
*   koops@csd.uwo.ca
*
*****
.
Xref: sparky comp.databases:5817 comp.databases.ingres:1014