Return-Path: owner-postman
Received: from localhost (localhost [127.0.0.1]) by nobozo.CS.Berkeley.EDU (8.6.4/8.6.3) with SMTP id LAA22611 for postgres-dist; Thu, 18 Nov 1993 11:22:54 -0800
Resent-From: POSTGRES mailing list <postman@postgres.Berkeley.EDU>
Resent-Message-Id: <199311181922.LAA22611@nobozo.CS.Berkeley.EDU>
X-Authentication-Warning: nobozo.CS.Berkeley.EDU: Host localhost didn't use HELO protocol
Sender: owner-postman@postgres.Berkeley.EDU
X-Return-Path: owner-postman
Received: from cs.uml.edu (cs.uml.edu [129.63.1.11]) by nobozo.CS.Berkeley.EDU (8.6.4/8.6.3) with SMTP id LAA22602 for <postgres@nobozo.CS.Berkeley.EDU>; Thu, 18 Nov 1993 11:22:50 -0800
Received: by cs.uml.edu id AA00577
  (5.67a+/IDA-1.5 for postgres@nobozo.CS.Berkeley.EDU); Thu, 18 Nov 1993 14:22:48 -0500
From: John Peter Lee <jlee@cs.uml.edu>
Message-Id: <199311181922.AA00577@cs.uml.edu>
Subject: warning upon appending my db - what is it ???
To: postgres@postgres.Berkeley.EDU
Date: Thu, 18 Nov 1993 14:22:46 -0500 (EST)
X-Mailer: ELM [version 2.4 PL22]
Content-Type: text
Content-Length: 2559      
Resent-To: postgres-dist@postgres.Berkeley.EDU
Resent-Date: Thu, 18 Nov 93 11:22:54 -0800
Resent-XMts: smtp


Hi:

  I'm using Postgres 4.0.1, and have the following problem:

  I'm getting a warning from postgres when I attempt to append a relation
  I just created, and I'd like to know what it is. Here is my program
  code snippet:

.
.
.	/* create the relation */

    query_result = (char *) PQexec ( "create comp_param_data (data_type =
    int4, fname = text, field_num = int4, fname_str_num = int4, missg_val =
    float4, n_samples = int4, n_miss_samples = int4, ndisc_values = int4,
    pos_first_disc = int4, min = float4, max = float4, mean = float4, std_dev
    = float4, norm_mean = float4, norm_std_dev = float4, dateflag = int4)" );

    check (query_result);  /* macro to print and exit if error */

    PQexec ("end");


printf ("append1 "); fflush(stdout);

  bzero (buf, 2048);

    /* append relation with parameter data info - date, id, 47 attribs */

       sprintf ( buf, "append comp_param_data ( data_type = %d, fname =
       \"%s\", field_num = %d, fname_str_num = %d, missg_val = %f, n_samples
       = %d, n_miss_samples = %d, ndisc_values = %d, pos_first_disc = %d, min
       = %f, max = %f, mean = %f, std_dev = %f, norm_mean = %f, norm_std_dev
       = %f, dateflag = %d )",
	    DISCRETE,
	   "date",
	   -1,
	   -1,
	   -1.0,
	    216,
	    0,
	    -1,
	    -1,
	    (float)min_date,
	    (float)max_date,
	    (float)mean_date,
	    -1.0,
	    -1.0,
	    -1.0,
	    TRUE
	    );

  PQexec ("begin");
  query_result = (char *) PQexec (buf);
  check (query_result);
  PQexec ("end");

printf("append2 "); fflush(stdout);

.
.
.


------------------------------------------------------------------------------
And this is the output, with warning:

artiste> convert

Going to initialize statistics values... Done
Set current database to "Finance"
Setting up Database Metadata... Done.
Setting up Parameter Data... append1 WARN:Nov 18 14:02:20:unequal type in
tlist : missg_val 

Error returned in status, =R
artiste> 


----------------------------------------------------------------------------

I'm using the printf() to print out the "append1" string, so I knew where
the problem started. it doesn't seem to like the "missg_val" field.

Any suggestions ???


thanks,

jp

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
JP Lee               Institute for Visualization and Perception Research	
jlee@cs.uml.edu                    University of Massachusetts at Lowell 
(508) 934-3384			      1 University Ave. Lowell, MA 01854

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
