Hi there,
How do I increase the width of a column in a table.
Can I do it without having to shut down the database?
Rgds
TDN
---(end of broadcast)---
TIP 3: if posting/reading through Usenet, please send an appropriate
subscribe-nomail command
Joseph Syjuco <[EMAIL PROTECTED]> writes:
> i want to put my count() result in a plpgsql declared integer variable
> declare f_count_var integer;
> begin
> select into f_count_var count(empno) from employee
> end;
> tried this one but it doesnt work
Works for me:
regression=# create functi
Tom,
> Done; I also added its sister function quote_ident. See the devel
> docs at
> http://candle.pha.pa.us/main/writings/pgsql/sgml/functions-string.html
Tante Grazie.
--
-Josh Berkus
---(end of broadcast)---
TIP 6: Have you searched our
"Josh Berkus" <[EMAIL PROTECTED]> writes:
> Well, first off, quote_literal isn't in the documentation under
> "Functions and Operators".So this is the first I've heard about it
> -- or probably anyone else outside the core team. How long has it
> been around?
Awhile; however, the only docum
Dirk,
> SELECT DISTINCT
> t_sek.docindex,
> t_sek.envelope,
> bt.oid,
> bt.time
> FROM
> boxinfo bt, boxinfo bd, boxinfo bo,
> docobj t_sek, docobj t_pgr, docobj t_sta, docobj t_sol,
> docobj d_pnr, docobj d_sta,
> docobj o_sek, docobj o_pgr, docobj o_pnr
> WHERE
> t_sek.docspe
When i make the set enable_seqscan = off the result is:
dbname=# set enable_seqscan = off;
SET VARIABLE
dbname=# explain analyze SELECT distinct(smsdate) FROM send_total;
NOTICE: QUERY PLAN:
Unique (cost=0.00..31084.39 rows=1232 width=8) (actual
time=108.60..195210.91 rows=6676 loops=1)
->
On 24 Jun 2002, Marcos Garcia wrote:
>
> When i make the set enable_seqscan = off the result is:
>
> dbname=# set enable_seqscan = off;
> SET VARIABLE
> dbname=# explain analyze SELECT distinct(smsdate) FROM send_total;
>
> NOTICE: QUERY PLAN:
>
> Unique (cost=0.00..31084.39 rows=1232 width=8)
On 24 Jun 2002, Marcos Garcia wrote:
> The problem is that my query is too slow when i use distinct:
>
> pgsql> explain analyze SELECT distinct(smsdate) FROM send_total;
>
> NOTICE: QUERY PLAN:
>
> Unique (cost=15840.31..15870.81 rows=1220 width=8) (actual
> time=56358.93..56452.78 rows=6670 l
try:
f_count_var := count(empno) from employee;
--- Joseph Syjuco <[EMAIL PROTECTED]> wrote:
>
> i want to put my count() result in a plpgsql
> declared integer variable
>
>
> declare f_count_var integer;
> begin
> select into f_count_var count(empno) from employee
> end;
>
> tried this
Joseph Syjuco wrote:
> hi
> i needed the variance function ... i dont know if i introduced the wrong
> parameters or maybe this variance is not the variance that im looking
> for but it doesnt provide the right results
>
> variance=(nEx^2 - (Ex)^2)/(n(n-1))
> my sql statement
> select variance(an
Joseph Syjuco <[EMAIL PROTECTED]> writes:
> i needed the variance function ... i dont know if i introduced the wrong
> parameters or maybe this variance is not the variance that im looking
> for but it doesnt provide the right results
> variance=(nEx^2 - (Ex)^2)/(n(n-1))
That's what I'd expect i
Hi,
I've a table "send_total" like this:
Table "send_total"
Column | Type |
Modifiers
---+--+---
id
Title: Message
Hi,
I have an objectid
field of type bigint, but when I run queries like:
select * from table
where objectid=123;
index is not used on
objectid even though it's declared.
However when I
run:
select * from table
where objectid='123';
index is
used.
Is there an
optionĀ I can
i want to put my count() result in a plpgsql declared integer variable
declare f_count_var integer;
begin
select into f_count_var count(empno) from employee
end;
tried this one but it doesnt work
---(end of broadcast)---
TIP 3:
On Thursday 20 June 2002 05:01 pm, you wrote:
> On Thu, 20 Jun 2002 15:23:53 +0200, Denis <[EMAIL PROTECTED]> wrote:
> >I traced the queries slowing it all down to this snippet in the debug log:
> >DELETE FROM phpbb_search_wordlist WHERE word_id IN (
> >SELECT word_id FROM phpbb_search_wordmatch W
hi
i needed the variance function ... i dont know if i introduced the wrong
parameters or maybe this variance is not the variance that im looking
for but it doesnt provide the right results
variance=(nEx^2 - (Ex)^2)/(n(n-1))
my sql statement
select variance(answer) from tbl_answer (where answer i
Hi,
On Sun, 23 Jun 2002, Christopher Kings-Lynne wrote:
>
> Use a subselect (and don't compare to 't' if it's a boolean field...)
>
> SELECT b_date FROM test WHERE active AND id=(SELECT min(id) FROM test) LIMIT
> 1;
It'a a shame for me that I could not think of using subselects :-(
Anyway, t
What exactly is your problem?
Calling a plpgsql function from within a C program
or retrieving varchar data within a C program?
Regards, Christoph
>
> I have a function that takes as a parameter ROWTYPE:
>
> create or replace function test_func(test_table)
> returns varchar as '
> declare
18 matches
Mail list logo