[SQL] Pattern Matchig

2008-04-08 Thread Tk421
Hello everybody I'm trying to make a query in a table to find the records who contains a full word 'im looking for. Here is an example about i'm trying code text 1foobar 2 foobar 3 foobar y 4foobar

Re: [SQL] Pattern Matchig

2008-04-08 Thread Tk421
Alvaro Herrera escribió: Tk421 escribió: The result is only record number 3. How can i search the entire FOOBAR word? The result wanted must be all, excepting 5. Something like this: select code from table where text ~ '[[:<:]]foobar[[:>:]]'

Re: [SQL] dateformat issue

2008-04-10 Thread Tk421
Gavin 'Beau' Baumanis escribió: Hi Everyone, I have a question about dates, please. I am using Coldfusion and Postgres I have a function that takes the ate entered in a form and converts it into an odbc date format. So the string ends up being; {d '2008-04-10'} Strangely, the function is us

[SQL] Problem inserting data

2008-06-20 Thread Tk421
Hello everybody. I''ve just converted an access database to postgres. The conversion was ok, but when i'm trying to insert data on some tables with boolean types from a Visual Basic application i receive an error. A sample: table example, with firs field of integer, second of type tex

Re: [SQL] Problem inserting data

2008-06-20 Thread Tk421
Adrian Klaver escribió: On Friday 20 June 2008 5:20 am, Tk421 wrote: Hello everybody. I''ve just converted an access database to postgres. The conversion was ok, but when i'm trying to insert data on some tables with boolean types from a Visual Basic applic

[SQL] A table with two names or table alias

2008-07-25 Thread Tk421
Can I create a table name alias? What i want is to access the same table with two different names. An example: I've the table CITY with fields code and name. I want to know if i can create an alternative name to table CITY, like LOCATION, to make possible these two sentences:

[SQL] Sequence and nextval problem

2008-11-24 Thread Tk421
Hello everybody. I've got an vb aplication that uses an Access database. I'm trying to convert the database to postgres. The conversion was done ok, but i've got a little problem that i don't know how to solve. Let's see if anyone can help me. The conversion from access database to

[SQL] EXECUTE query INTO problem

2008-11-25 Thread Tk421
I've got a problem with a function: It receives two parameters, the first, the table name, and the second, a where condition. The function looks like this: DECLARE cod bigint; query TEXT; BEGIN query = 'SELECT codigo FROM ' || $1 || ' WHERE ' || $2; EXECUTE qu

[SQL] Problem inserting image

2008-12-22 Thread Tk421
    I've made a routine in VB to insert a image into a table. The code is:          Set cmd = New ADODB.Command     cmd.ActiveConnection = objconexion     cmd.CommandText = "INSERT INTO tb_tmp_ventanas (ventana) VALUES (?)"     archivo = "c:\image.jpg"     fd =

Re: [SQL] How to Import Excel Into PostgreSQL database

2008-12-24 Thread Tk421
    Try this: http://sqlmanager.net/products/postgresql/manager/         It's an application that includes a lot of tools for importing and exporting databases. It's the best tool i've used for these kind of actions, and to manage postgreSQL databases Venkat Rao Tammineni escribió: