Bui Anh Tin shaped the aether and said:

> 
>  SELECT ( '../admin.aspx?com=addmap&type=edit&id=' ,mapid) as edit form
> mytable
> 
> mapid is interger
> but it error
>

It helps if you include the version of PostGreSQL that you are running (select 
version() at a psql prompt will tell you); I suspect that this is 8.3.x because 
it has gotten rid of some implicit casts, especially where numbers are 
concerned.

You might try:

 SELECT ( '../admin.aspx?com=addmap&type=edit&id=' || mapid::text)

This is untested as the SQL you provide is not the SQL you ran -- "as edit 
form" is probably "AS edit FROM" -- not the transposed letters in the last 
word. It helps if you can actually quote exactly what you did since an 
accidentally introduced typo can break an SQL statement.

I am guessing you want to append the mapid value to a string -- "||" is one 
concatenation operator.

HTH,

Greg Williamson
Senior DBA
DigitalGlobe

Confidentiality Notice: This e-mail message, including any attachments, is for 
the sole use of the intended recipient(s) and may contain confidential and 
privileged information and must be protected in accordance with those 
provisions. Any unauthorized review, use, disclosure or distribution is 
prohibited. If you are not the intended recipient, please contact the sender by 
reply e-mail and destroy all copies of the original message.

(My corporate masters made me say this.)

_______________________________________________
postgis-users mailing list
[email protected]
http://postgis.refractions.net/mailman/listinfo/postgis-users

Reply via email to