3

I'm familiar with SQL in SQLite and MySQL, but OpenOffice Base seems to be either very crippled, or I don't understand how to execute raw SQL.

I want to do (effectively) this:

INSERT INTO t2 SELECT NULL as id, t.foo, t.bar, '' as baz, 0 as quux 
  FROM MyTable t

All I can do is

SELECT t.foo, t.bar, '' as baz, 0 as quux FROM MyTable t

because the NULL seems to give Base confusion, as does the INSERT INTO T2 SELECT ... syntax.

Can anyone suggest how I need to fix this?

BoltClock
  • 700,868
  • 160
  • 1,392
  • 1,356
Jason S
  • 184,598
  • 164
  • 608
  • 970

1 Answers1

3

Indeed, NULL is not accepted there. It should. Could you please file this as a bug and assign it to lionel@mamane.lu so that I don't forget to fix it? Thanks.

In general, to avoid Libre/OpenOffice from trying to parse/understand your query, and send it to the database engine pristine as-is, use "run sql command directly" or "analyze SQL: no"

BoltClock
  • 700,868
  • 160
  • 1,392
  • 1,356
  • but I'm not using LibreOffice... if you fix it there, is it likely your fix makes it into OpenOffice? – Jason S Feb 16 '12 at 23:35
  • @JasonS The Sun/Oracle OpenOffice.org project does not exist any more (stopped by Oracle). In my judgement, of the two projects that forked it and consider themselves as "natural" successor (LibreOffice and Apache Incubator), the more active one is LibreOffice: It has many of the non-Sun/Oracle coders (and some of the Sun/Oracle coders under new employers) of the old OpenOffice.org project. It has released three major versions and nine bugfix/maintenance releases, versus zero for the Apache Incubator. – Lionel Elie Mamane Feb 17 '12 at 07:18