[Babase] Query error?

Catherine Markham amarkham at princeton.edu
Fri Aug 25 10:20:48 EDT 2006


Thanks, Karl.  I tried rerunning the query from home this morning, but 
things froze up on me.  I just gave it another shot and had better luck 
with the site.  Here's the specific error message:

Total runtime: 4,257.513 ms
SQL executed.
1 error(s) in script.

The table the query produced looks correct, but I'm just worried
something is off because of the "error in script" part.

In response to Karl's specific questions, I see what you mean - it does 
work without any errors when you take out the saving it into a table 
part.  I did have the right pathway set yesterday (I know because the 
table was saved in the correct location).  But I changed the query a bit 
anyway to specify the following (still got the same error message):

create table amarkham.play6 as
select * from repstats where state = 'P' and date > '1999-12-31' and 
date < '2006-01-01' order by date;

Sorry, but I still don't get what is causing the trouble.  And, nope, I 
don't think the number in the table name has anything to do with it - I 
get the same error if I name the new table something with only letters.

Thanks,
Catherine


Karl O. Pinc wrote:
> 
> On 08/24/2006 09:21:09 PM, Catherine Markham wrote:
>> Karl,
>>
>> I'm working at home at right now and it looks like I don't have the 
>> link to the online website.  If you're online, can you send me the 
>> address and I'll try to recreate the query error?
> 
> https://papio.biology.duke.edu/phpPgAdmin/
> 
>>
>> Thanks,
>> Catherine
>>
>> Karl O. Pinc wrote:
>>>
>>> On 08/24/2006 09:02:48 PM, Catherine Markham wrote:
>>>> Hi all,
>>>>
>>>> I have a question about the query below.  We were working in the new 
>>>> system this afternoon and Laurence wanted to select all the rows in 
>>>> repstats where a female was pregnant during 1999-2005.  What I tried 
>>>> was:
>>>>
>>>> create table play4 as
>>>> select * from repstats where state = 'P' and date > '1999-12-31' and 
>>>> date < '2006-01-01' order by date;
>>>>
>>>> This did give us an output which, as far as we could tell, seemed 
>>>> correct.  However, the system displayed a message saying there was a 
>>>> query error.
>>>>
>>>> Karl and Leah, do you see the mistake?
>>>
>>> What was the error message?  That's the first question.
>>>
>>> Unless your search path is set to put your personal schema
>>> first then you're trying to create a table in the babase
>>> schema and you don't have permissions to do so.  Qualify
>>> the table name with the schema.  (amarkham.play4)
>>>
>>> Can you have a table name with a digit in it?
>>>
>>> The select statement works, so it must be in the create table
>>> part if it's a syntax error.
>>>
>>> Karl <kop at meme.com>
>>> Free Software:  "You don't pay back, you pay forward."
>>>                  -- Robert A. Heinlein
>>>
>>> _______________________________________________
>>> Babase mailing list
>>> Babase at www.eco.princeton.edu
>>> http://www.eco.princeton.edu/mailman/listinfo/babase
>> _______________________________________________
>> Babase mailing list
>> Babase at www.eco.princeton.edu
>> http://www.eco.princeton.edu/mailman/listinfo/babase
> 
> Karl <kop at meme.com>
> Free Software:  "You don't pay back, you pay forward."
>                  -- Robert A. Heinlein
> 
> _______________________________________________
> Babase mailing list
> Babase at www.eco.princeton.edu
> http://www.eco.princeton.edu/mailman/listinfo/babase



More information about the Babase mailing list