Subject: warning upon appending my db - what is it ???

From: John Peter Lee <[email-masked]>
Date: Thu, 18 Nov 1993 14:22:46 -0500 (EST)

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	
[email-masked]                    University of Massachusetts at Lowell 
(508) 934-3384			      1 University Ave. Lowell, MA 01854

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