Re: [ADMIN] SQL Script
Re: [ADMIN] SQL Script
От:
David Stanaway <david@netventures.com.au>
Дата:
On Wednesday, January 30, 2002, at 12:12 PM, lonh SENG wrote: > Hi all, > =A0 > =A0=A0=A0 I have one table containing data as "source.txt" attached file.= I=20 > want to create a script to clean=A0the data and get the result as=20 > "result.txt" attached file. > =A0=A0=A0 inbtime and inbtime1 is datetime data type. > =A0=A0=A0 Anyone has an idea? > =A0=A0=A0 Any help will be appreciated. > =A0=A0=A0 thanks in advance It looks like you are going to need to look into using a cursor, and=20 perl DBI or equiv. Alternatively, you could create a function in=20 PL/PGSQL. Where do you get the date for the end of the interval for the last=20 inbtime ordered by time? =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D David Stanaway Personal: david@stanaway.net Work: david@netventures.com.au