Hi,
I'd like to update a table efficiently where the relevant select-info
is in another table that is foreign-linked.
Stupid example. 2 tables:
things (thing_id integer, name varchar(100), color varchar(100))
inventory (item_id integer, thing_fk integer references things
(thing_id), number)
gle'
Then I want to match abbrevations like 'A-Company Ltd.', 'a company
ltd.', 'A-Company Limited'
Is there a way to do this?
It would be OK just to list candidats up to be manually checked afterwards.
Regards
Andreas
--
Sent via pgsql-sql mailing
a fk<>0 row
that has the same group_nr ?
I'd like to get just:
994001, Tick,1, 40, 994010
4002, LEADS, 2, 40, 0
994003, Track, 3, 40, 994010
Regards
Andreas
--
Sent via pgsql-sql mailing list (pgsql-sql@postgresql.org)
To make changes to your su
Hi,
I get from an outside source tables as simple textfiles to import.
Those are obviously results of views with joined tables.
Among the normal stuff are columns that have one or a list of id-numbers
devided by a semicolon.
In the next column there is the corresponding text for this ids.
It
Hi,
I'd like to update some records in a table.
Those have a status_id and among other columns a varchar with a name and
a create_date.
The status_id is 0 if nothing was done with this record, yet.
For some reasons I've got double entries which I now want to flag to -1
so that they can be sor
Hi,
yes, there is a serial as primary key. Lets call it "id".
Therfore one could use this to find the oldest record.
Regards
Andreas
Oliveiros Cristina schrieb:
Andreas,
Does your table has any field that can be used as primary key? Any
"ID" field?
Best,
Olivei
Hi,
I need a function that removes characters in strings that aren't in a
given set of chars.
e.g
Input:12-34/ 56(8)
I want just numbers so Output should in this case be: 1234568
Is there a solution?
--
Sent via pgsql-sql mailing list (pgsql-sql@postgresql.org)
To make changes to your s
; and "+49" --> 0
while international numbers
+33/123456789
0033/123456789
should come as
+33123456789
I fear the hard part is that international codes have 1-3 digits :(
Regards
Andreas
ivan Stoykov wrote:
regexp_replace('120323423 23(fdf_)fd','[^[:digit:]]'
)
, E'^(?:\\+||00)(.*)', E'\\1')
else
regexp_replace(p, E'[^0-9]', '', 'g')
end
That would catch the leading spaces in " 00 49 ( 0 ) 1 2 3 456 -0", too.
Creating a sql-function thows a WARNING: nonstandard use of \\ in a
strin
rect way to code the backslashes to avoid the Warning?
Regards
Andreas
Raj Mathur schrieb:
On Tuesday 17 Feb 2009, Andreas wrote:
[snip]
case
when regexp_replace(p, E'[^0-9+]', '', 'g') ~ E'^(\\+|00)49'
then '0'||
regexp_rep
L', ' is ', ' great'--> 'PostgreSQL is great'
NULL, ' is ', ' great' --> 'great'
'PostgreSQL', ' is ', NULL--> 'PostgreSQL'
NULL, ' is ', NULL --&
No.
B should only appear if A and C are not empty.
B is just a filler.
Thanks
Andreas
A. Kretschmer schrieb:
In response to Andreas :
I'd like a function that concats 3 string parameters on condition the
1st and 3rd are NOT empty or NULL.
xCat (s1, s2, s3)
s2 would be a connector
thing(rs.getString("col1"), rs.getString("col2"),
rs.getString("col3"), rs.getString("col4") );
So I have to serve my servlet with any kind of datasets and I really
can't imagine, that such a basic task isn't possible with PostgeSQL.
Kind regards
Andreas.
rking. Not very clever, but should
work, hopefully.
3) Use another database server, could be Interbase but I would prefer
PostgreSQL.
Could somebody please help me to decide which strongle depends from the
SQL procedure problem.
Kind regards
Andreas.
ng feature?
Kind regards
Andreas.
change
to the data set
I hope someone has this quite usual feature handy or at least a
pointer where this is described.
Thank you very much
Andreas.
r
> 7.1, and I'm not sure if we will be able to do it for 7.2
> yet.
Just to make sure you've got to know that this is a feature needed
by many users: Add me to the list of users who have a big need for
this!
Kind regards
Andreas.
r you mentioned
> CREATE TRIGGER myt_stamp BEFORE INSERT OR UPDATE ON mytable
> FOR EACH ROW EXECUTE PROCEDURE myt_stamp();
the function could cause errors.
Sorry, I'm not very familiar with this function stuff :-(.
Kind regards
Andreas.
gt;
> Create table fred (joe integer, createdtime datetime not null default text
> 'now');
>
> If you dont put the text in you get the date the table was created in all
> future inserts. The text force the current now to be used.
> ?Is this fixed in 7.0.x
Would do a better job in this case?
What's wrong here?
Kind regards
Andreas.
work and what copy function fails here??
Kind regards
Andreas.
c (@Query)
Select @num=(Select Max(Num) From #NumTable)
Drop Table #NumTable
return @num
May be there are some clever ways to avoid the temporary table.
I really wonder if my solution is in fact very clever because I'm unsure
if it is thread-safe.
Any hints?
Kind regards
Andreas.
ROR: parser: parse error at or near "changedat"
What's the problem here. Is there a conflict between the definition with
DEFAULT now() and the TRIGGER BEFORE INSERT OR UPDATE. Should perhaps
be the DEFAULT in the definition be removed or just the INSERT in
the TRIGGER? Or is there a completely different problem?
Kind regards
Andreas.
NEW.ChangedAt := timestamp(''now'');
> RETURN NEW;
> END;
> ' LANGUAGE 'plpgsql';
>
> I didn't test it, but as pgSQL looks like Oracle, it should be ok :-)
This avoids the error message, but doesn't have any effect to the value
of ChangedAt. It just remains the same as CreatedAt :-(.
Kind regards
Andreas.
re's hint to "put null" into the
field.
Bay the way: If we once solved the problem it might be a topic for
the FAQ, perhaps?
Kind regards
Andreas.
res server) has changed the
data set while I was edditing it? (In general it's no problem, but
if I try two changes immediately the second change will be started
with this boring warning.) But this is perhaps off topic in this
list
Kind regards and many thanks to you all
Andreas.
ith
Exec ( query )
Kind regards
Andreas.
On Mon, 28 Aug 2000, Yury Don wrote:
> Andreas Tille wrote:
> >
> > Create Function VarSelect ( varchar, varchar )
> >returns int
> >As '
> > Declare num int ;
> >
> > Begin
> >Select Into num Count(*
.
I have to admit that my boss wonders why I'm switching from a working
solution (MS SQL) to so much trouble :-(. I really hope to convince him
to OpenSource but it's much harder than I expected.
Kind regards
Andreas.
w to PostgreSQL.
Hopefully some other PostgreSQL users besides me will love you for that .
Kind regards
Andreas.
ERROR: function declared to return varchar returns multiple values in final retrieve
If O just remove the ORDER BY clause als works well so I guess that the
ORDER BY has to be replaced by somethjing other. Could somebody
enlighten me how to do the ordering in a stored procedure?
Kind regards
Andreas.
re or less beginners like me regarding
when to use views and when to use functions?
Kind regards
Andreas.
you have continuos headache while trying to port a database.
I think I'm not the only one who would be really, really happy if
*real* stored procedures would be high on top of the todo list.
(In fact this is the *only* thing I'm currently really missing in
PostgreSQL.)
Kind regards
Andreas.
reference, that was requested by the application.
Is there anybody out there who can be of help on that matter? I really tried to
find an answer myself, but now I'm stuck.
Any help is highly appreciated. Thanks in advance,
Andreas (Vienna, Austria, Europe, Earth)
for your ongoing hard work!
Couldn'trepeated often enough alos for the past!
Kind regards
Andreas.
ould be a match. As is, this
> compare is case sensitive.
select * from account where lower(username) = 'test';
Dipl.Ing. Andreas Manessinger - CCT / Competence Center Telematik
Magistrat der Stadt Wien, Magistratsabteilung 14 - ADV,
Rathausstr. 1, A-1082 Wien
E-Mail: [EMAIL PROTE
check(s)
ERROR: UNIQUE constraint matching given keys for referenced table "reskulturdetail"
not found
Can anybody explain, why the foreign key constraint fails?
Thanks and have a nice weekend
Andreas.
---(end of broadcast)---
r or modify the query
If I remove the DISTINCT keyword it works:
select tnr, titel, 'TEST' AS testcol from tTitel;
Greetings,
Andreas
---(end of broadcast)---
TIP 6: Have you searched our list archives?
http://archives.postgresql.org
Id)+1 from Items where Id < 100;'
LANGUAGE 'sql';
I did not found any trace of documentation how to do an explicit typecast
for the function. Defining the function first fails because:
ERROR: Relation "items" does not exist
Any hint to solve
Ids.
But anyway for academic reasons: What means adding 'explicit typecast'
of a func???
I was not able to find this term in the docs.
Kind regards
Andreas.
---(end of broadcast)---
TIP 4: Don't 'kill -9' the postmaster
On Wed, 14 Aug 2002, Tom Lane wrote:
> I concur with Richard that Andreas needs to solve a different problem,
> but just for the record, the way you could do it is
>
> CREATE TABLE without mentioning the default
>
> CREATE FUNCTION
>
> ALTER TABLE
gger: function fix_status() does not exist
Why doesn't the trigger acknowledge that I want to call fix_status with a
parameter for which table name I should use?
I'm completely stuck and I someone out there can help me.
-> Andreas
---(end of broadcast)---
TIP 1: subscribe and unsubscribe commands go to [EMAIL PROTECTED]
your patience
Andreas.
---(end of broadcast)---
TIP 5: Have you checked our extensive FAQ?
http://www.postgresql.org/users-lounge/docs/faq.html
On Sat, 24 Aug 2002, Mark Stosberg wrote:
> On Thu, 22 Aug 2002, Andreas Tille wrote:
> > Hello,
> >
> > I want to solve the following problem:
> >
> > CREATE TABLE Ref( Id int ) ;
> > CREATE TABLE Import ( Idint,
>
led
COPY statements.
I've thought that including all data and handling them afterwards would
be agood idea and it is just my lack of SQL knowledge which prevents
me from finding a clever solution to sort the stuff out.
Kind regards
Andreas.
---(end of broadcast)---
TIP 4: Don't 'kill -9' the postmaster
d be possible. That's why I had the idea just to
set a certain flag and then do the insert of all data sets where flag = OK.
Kind regards
Andreas.
---(end of broadcast)---
TIP 3: if posting/reading through Usenet, please send an approp
". but I am not sure if
this will display your needs. Do you really need the data like "ORD0244,
ORD0245..." ? Then you should use an array or set datatype. They are
normally not nice to handel.
regards
-andreas
--
Andreas Schmitz - Phone +49 201 8501 318
Cityweb-Te
Hi,
once I subscribed to this list I've got the information how to
subscribe:
If you ever want to remove yourself from this mailing list,
send the following command in email to
[EMAIL PROTECTED]:
approve unsubscribe Andreas Tille <[EMAIL PROTECTED]>
Well, I did so bu
e command to majordomo as usual for mailing lists,
but if I get those explicite advise ...
Next try:
mailx -s unsubscribe [EMAIL PROTECTED] <<...
unsubscribe
...
Let's see what happens ...
Andreas.
---(end of broadcast)---
T
1
JOIN tab2 T2 ON T1.key=T2.Key <<<<<<
WHERE T2.restr=1
I'm looking for a portable query style, without using a subquery in the
SET clause (which could make things quite slow)
Any hints?
Regards,
Andreas
---(end of broadcast)-
Hi,
you also have to drop the sequence.
drop sequence kokot_kokot_seq;
regards
-andreas
On Friday 02 May 2003 14:20, Rado Petrik wrote:
> Hi,
>
> 1) When I create new table expample.
>
> CREATE TABLE "kokot" (
> "kokot" SERIAL );
>
>
> 2) and
rom tipp_team_members where member_team_id=2 and
member_user_id=27;
WARNING: Error occurred while executing PL/pgSQL function
update_team_member_count
WARNING: line 13 at if
ERROR: Attribute "delete" not found
tippspiel2003=#
What am I making wrong ?
best regards
-Andreas Schmitz
--
An
ed correctly but the ranking is a mess. I
recongnized that the select seems to follow primarily the internal table
order. Is there any way to solve this nicely. Hints and solutions are
appreciated.
Thanks in advance
-Andreas
--
Andreas Schmitz - Phone +49 201 8501 318
Cityweb-Technik-Serv
result SETOF MyTable ;
BEGIN
result := (SELECT * FROM MyTable);
RETURN result ;
END; ' LANGUAGE 'plpgsql';
wich failed.
Kind regards
Andreas.
---(end of broadcast)---
TIP 5: Have you checked
QL function plpgsqldepartmentsalaries
WARNING: line 5 at return next
ERROR: Set-valued function called in context that cannot accept a set
test=#
Any hint what might be wrong here? I'm using PostgreSQL 7.3.2 under Debian
GNU/Linux (testing).
Kind regards
Andreas.
---(end of broadcast)---
TIP 7: don't forget to increase your free space map settings
On Thu, 27 Nov 2003, Joe Conway wrote:
> Andreas Tille wrote:
> > test=# select PLpgSQLDepartmentSalaries() ;
>
> This should be:
> regression=# select * from PLpgSQLDepartmentSalaries();
> departmentid | totalsalary
> --+-
> 1 |
all records.
The fastes solution I found until now was not to
use any data base, sort the data with the unix command sort and process the
logfile text directly with perl.
Thanks in advance!
Andreas
Hello,
is there any equivalent for ORACLEs decode() in pl/pgsql ?
regards,
-Andreas
--
---(end of broadcast)---
TIP 6: Have you searched our list archives?
http://archives.postgresql.org
System Administrator
22004-01-01 12:00:00 infinity Guest
Table "t_person" could have the following contents:
id begin_val end_valusername role
=====
120
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1
Hi!
Many thanks for your reply!
Tom Lane wrote:
> Andreas Haumer <[EMAIL PROTECTED]> writes:
>
>>It seems I would have to use EXECUTE on dynamically constructed
>>PL/PGSQL statements in order to have my trigger function re
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1
Hi!
I have solved the problem!
Tom Lane wrote:
> Andreas Haumer <[EMAIL PROTECTED]> writes:
>
>>I just can't figure out where and how many quotation marks
>>I have to place in my function.
>
>
> It's messy
at this is of course very platform specific. On Oracle
you could use rownum, for example.
I don't have a more portable solution on hand right now.
HTH
- - andreas
- --
Andreas Haumer | mailto:[EMAIL PROTECTED]
*x Software + Systeme | http://www.xss.co.at/
Karm
Sascha Ziemann writes:
> it is defined in this way:
[...]
> CONSTRAINT constraint_name ON table_name |
Well then...
> comment on constraint uni on table tab3 is 'unique pair';
^
...why do you insert "table" when it is defined
am Sat, dem 27.11.2004, um 12:55:40 -0500 mailte Keith Worthington folgendes:
> Hi All,
>
> I have two tables in different schemas. The first table in the data_transfer
> schema is loaded with a COPY command. I need to transfer the data to the
> second schema inserting new records and updating
OCOMMIT
\set AUTOCOMMIT FALSE
begin;
But this works only one transaction.
regards, Andreas
--
Andreas Kretschmer(Kontakt: siehe Header)
Tel. NL Heynitz: 035242/47212
GnuPG-ID 0x3FFF606C http://wwwkeys.de.pgp.net
===Schollglas Untern
select id, sum(summe) from (select id, sum(quantity) as summe from tbl3 where
order_id in (select order_id from tbl2 where closed = false) group by id union
select id,0 from tbl1 group by id) as x group by x.id order by x.id;
and this result:
id | sum
--+-
AB12 | 15
CD34 | 5
); using UNION in place of an outer join is _very_ unwise. (In fact
> UNION / INTERSECT / EXCEPT should normally be reserved for those cases
> where there is simply no alternative.)
Okay. I'm learning ;-)
Andreas
--
Diese Message wurde erstellt mit freundlicher Unterstützung eines fre
for this task? I would prefer a smallint for this with a
check-contraint to check the values.
> be as fast as possible.
>
> considering that almost 70% of the rows will be with 'VALUE1', 20%
> will be with 'VALUE2' and 10% will be with 'VALUE3' on the
d'
test-# when fruit = 2 then 'bad'
test-# when fruit = 3 then 'rotten' end from fruit;
name | fruit | case
+---+
Apple | 1 | good
Banana | 2 | bad
Cherry | 3 | rotten
(3 Zeilen)
Please read
http://www.postgresql.org/docs/7.4/interactive
and 'rotten' under the column 'fruit'?
Yes, simple:
test=# select name, case
test-# when fruit = 1 then 'good'
test-# when fruit = 2 then 'bad'
test-# when fruit = 3 then 'rotten' end as fruit from fruit;
name | fruit
----+
Apple
am 16.12.2004, um 8:10:25 -0600 mailte Bruno Wolff III folgendes:
> On Thu, Dec 16, 2004 at 12:01:39 +0100,
> Andreas Kretschmer <[EMAIL PROTECTED]> wrote:
> > >
> > > considering that almost 70% of the rows will be with 'VALUE1', 20%
> > > w
you can walk through all database via 'psql -l' and then
walk through all tables in every database via 'echo "\d " | psql db'.
You get all tables in all databases and now you can do a 'revoke' on
this tables.
But i'm afraid, there is a better way to do th
from geo where id=1;'
fails. If I do 'select area(box(koerper)) from geo where id=1;' it
works, but this isn't the right answer. Is this a limitation for area()?
Version is 7.4.5.
Regards, Andreas
--
Diese Message wurde erstellt mit freundlicher Unterstützung eines fre
am Sun, dem 19.12.2004, um 11:38:40 +0100 mailte Kretschmer Andreas folgendes:
> Now, I need the area, but 'select area(koerper) from geo where id=1;'
> fails. If I do 'select area(box(koerper)) from geo where id=1;' it
> works, but this isn't the right ans
rs in 28672 seconds:
test_db=# select 28672 / 3600;
?column?
--
7
(1 Zeile)
Now you can add 24 hours and 7 hours, the remainder is
test_db=# select 28672 - 3600*7;
?column?
--
3472
(1 Zeile)
seconds. Now you can calculate the minutes and, finaly, the seconds.
went through some documentation
> and found out that it is possible through dblink.
>
> I infact downloaded the dblink package in contrib folder. But still when i
> tried to use dblink in the following manner:
You must run the dblink.sql, not only download.
Regards, Andreas
--
Di
problem is, i need also rows for machine and week with no entrys in
the table. For this rows the sum(area) shold be NULL ore 0.
In other words: for every machine i need M rows, and M must be constant.
Regards & Thx, Andreas
--
Diese Message wurde erstellt mit freundlicher Unterstützung eines fre
am 26.01.2005, um 10:13:52 +0200 mailte Din Adrian folgendes:
> Hello,
> I am want to use a private table in postgresql(every client to see his own
> data).
> Is this possible? How can I do it!
Why?
You can create different users and/or different databases.
Regards, Andreas
am Wed, dem 02.02.2005, um 9:33:22 -0600 mailte Bradley Miller folgendes:
> Is there a way to dump everything in a particular schema?
RTFM.
man pg_dump, search for --schema
Regards, Andreas
--
Diese Message wurde erstellt mit freundlicher Unterstützung eines freilau-
fenden Pinguins
rently the context on DB bbb?
Yes, take a look at dblink (contrib-package)
Andreas
--
Andreas Kretschmer(Kontakt: siehe Header)
Heynitz: 035242/47212, D1: 0160/7141639
GnuPG-ID 0x3FFF606C http://wwwkeys.de.pgp.net
===Schollglas Unternehmensgruppe===
--
meter,oe_count_matches(smiles,smarts) as
> count,
> round((parameter*oe_count_matches(smiles,smarts)),2) as
> psa,tpsa(smiles) as ctpsa,tpsa
> from structure,tpsa
> where id < 237610
> and oe_count_matches(smiles,smarts) > 0
try ... round((parameter*oe_count_m
linux-gnu, compiled by GCC i386-linux-gcc (GCC)
3.3.5 (Debian 1:3.3.5-5)
(1 Zeile)
Regards, Andreas
--
Andreas Kretschmer(Kontakt: siehe Header)
Heynitz: 035242/47212, D1: 0160/7141639
GnuPG-ID 0x3FFF606C http://wwwkeys.de.pgp.net
===Schollglas Unternehmensgruppe===
--
am 06.04.2005, um 13:55:35 +0700 mailte bandeng folgendes:
> hello guys,
>
> I want to use crosstab function but that function it doesnt exist. my
> version is 7.3 so how do i get the tablefunc.sql from postgre contrib?
apt-get install postgresql-contrib
Regards, Andreas
he pg_hba.conf. Read this about -i and TCPIP_SOCKET and
edit this to enable access via tcp/ip.
Andreas
--
Andreas Kretschmer(Kontakt: siehe Header)
Heynitz: 035242/47212, D1: 0160/7141639
GnuPG-ID 0x3FFF606C http://wwwkeys.de.pgp.net
===Schollglas Unternehmensgruppe===
--
a file for
> the sql instructions but right on the same line. I use very short psql
> commands and would like to do it all with 1 file.
echo "select bla from fasel" | psql -U database
You can also use here documents, shell-variables and so on.
Regards, Andreas
--
Andreas Kre
i'm using 7.4.6.
Is there now a way to get the total number of rows in a CURSOR?
Andreas
--
Andreas Kretschmer(Kontakt: siehe Header)
Heynitz: 035242/47212, D1: 0160/7141639
GnuPG-ID 0x3FFF606C http://wwwkeys.de.pgp.net
===Schollglas Unternehmensgruppe===
-
trib on dblink.
You should look in the archiv of the list, Tom Lane and other people
described the way with dblink in the past.
Andreas
--
Andreas Kretschmer(Kontakt: siehe Header)
Heynitz: 035242/47212, D1: 0160/7141639
GnuPG-ID 0x3FFF606C http://wwwkeys.de.pgp.net
===Schollglas
erent db site. Tq in
> advance.
1. write your own client thats connect to several databases
2. use dblink, this is part of the contrib-distribution
Andreas
--
Andreas Kretschmer(Kontakt: siehe Header)
Heynitz: 035242/47212, D1: 0160/7141639
GnuPG-ID 0x3FFF606C http://wwwkeys.de.pgp
his should solve your perfomance-problem.
Regards, Andreas
--
Andreas Kretschmer(Kontakt: siehe Header)
Heynitz: 035242/47212, D1: 0160/7141639
GnuPG-ID 0x3FFF606C http://wwwkeys.de.pgp.net
===Schollglas Unternehmensgruppe===
---
am 22.05.2005, um 10:17:53 +0200 mailte Andreas Kretschmer folgendes:
> > can you help me how to fix them.
> > Can I using function to fix them (how?)
>
> It is possible to create a extra table for the balance and a trigger for
> insert/update that calculates the balance
ENT_DATE;
date
2005-05-23
(1 Zeile)
Regards, Andreas
--
Andreas Kretschmer(Kontakt: siehe Header)
Heynitz: 035242/47212, D1: 0160/7141639
GnuPG-ID 0x3FFF606C http://wwwkeys.de.pgp.net
===Schollglas Unternehmensgruppe===
--
0
2005-05-23
(2 Zeilen)
test=# select * from datediff where CURRENT_DATE - start > 10;
start
1966-08-30
(1 Zeile)
test=# select * from datediff where CURRENT_DATE - start < 10;
start
2005-05-23
(1 Zeile)
Btw.: please no TOFU, read http://en.wikipedia.org/wi
am 24.05.2005, um 17:59:31 -0300 mailte [EMAIL PROTECTED] folgendes:
> Hi.
> How can I delete the duplicated records with "DELETE FROM TABLE WHERE..."
> clause??
Please read http://www.gtsm.com/oscon2003/deletetid.html
Its a very good article about this problem.
Regards,
=# insert into blub values (1, 'x');
| INSERT 970706 1
| test_db=# insert into blub values (1, 'y');
| FEHLER: duplizierter Schlüssel verletzt Unique-Constraint >>blub_pkey<<
`
In other words: if there a primary key on the first row, you cannot
insert duplicates.
h a RULE or a TRIGGER.
Regards, Andreas
--
Andreas Kretschmer(Kontakt: siehe Header)
Heynitz: 035242/47212, D1: 0160/7141639
GnuPG-ID 0x3FFF606C http://wwwkeys.de.pgp.net
===Schollglas Unternehmensgruppe===
---(end of broadcast)---
am 09.06.2005, um 3:29:15 -0500 mailte Bruno Wolff III folgendes:
> On Thu, Jun 09, 2005 at 09:18:09 +0200,
> Andreas Kretschmer <[EMAIL PROTECTED]> wrote:
> > am 09.06.2005, um 12:36:31 +0530 mailte Kenneth Gonsalves folgendes:
> > > hi
> > > i have a tab
195
>
>
> Select * from tbl_xxx where
> tbl_xxx.A2=substr('196895588454554545454',0,char_length(tbl_xxx.A2)+1);
Perhaps because char_length() returns NULL and this is a invalid value
for substr(). Use coalesce():
... substr('196895588454554545454',0,coalesce(ch
am 20.06.2005, um 11:45:55 +0200 mailte Luca Rasconi folgendes:
> I need to know if somebody read this mail.
Yes, i read it ;-)
Regards, Andreas
--
Andreas Kretschmer(Kontakt: siehe Header)
Heynitz: 035242/47212, D1: 0160/7141639
GnuPG-ID 0x3FFF606C http://wwwkeys.de.pgp.
-
> 7349453 | admintool |5436 | 100 | admintool | |
> 7349454 | postgres |5437 |1 | postgres | |
> (2 rows)
>
> But 'current_query' is still always empty... B-(
enable stats_command_string in your postgresql.conf
Re
)
scratch=# select '1'::char(3) ~ '^\\d+\\s*$';
?column?
--
t
(1 row)
scratch=# select '1'::varchar(3) ~ '^\\d+$';
?column?
--
t
(1 row)
--8<---cut here---end--->8---
regards
Andreas
--
---(end of broadcast)---
TIP 6: explain analyze is your friend
101 - 200 of 455 matches
Mail list logo