Search Postgresql Archives

Re: [SQL] check data for datatype

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



I guess that could need something like (untested)

delete from bigtable text_column !~ '^[0-9][0-9]*$';


HTH
Gerardo

----- Mensaje original -----
> De: "Suresh Raja" <suresh.rajaabc@xxxxxxxxx>
> Para: pgsql-general@xxxxxxxxxxxxxx, pgsql-sql@xxxxxxxxxxxxxx
> Enviados: Viernes, 27 de Marzo 2015 15:08:43
> Asunto: [SQL] check data for datatype
> 
> 
> 
> 
> 
> 
> 
> 
> Hi All:
> 
> 
> I have a very large table and the column type is text. I would like
> to convert in numeric. How can I find rows that dont have numbers. I
> would like to delete those rows.
> 
> 
> Thanks,
> -Suersh Raja


-- 
Sent via pgsql-general mailing list (pgsql-general@xxxxxxxxxxxxxx)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general




[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]
  Powered by Linux