Merge data from Kexi to KWord

View: New views
5 Messages — Rating Filter:   Alert me  

Merge data from Kexi to KWord

by John Jason Jordan-2 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

I can't get it to work.

I go into Tools > Configure Mail Merge > Open Existing, and in the
popup I select Qt-SQL Source (power user) - which is the only choice -
and then I click on OK.

This gives me another popup asking for Hostname, Driver, Database name,
Username and Port. I enter the name of the computer (Devil7), leave the
driver at QMYSQL3 (the only option), drag the database file from
Nautilus into the Database Name box (the filename appears correctly),
enter my username (jjj), and leave the Port at "default."

When I click on OK, I am prompted for the password, so I enter the root
password. And then I get "Can't connect to MySQL server on
'Devil7' (111)."

I suspect that putting "Devil7" in the top box is wrong, but I can't
find anything in the Help files that explains where to tell KWord to
look for the file. The file is right here on the same computer as KWord
- not on a networked server somewhere.

Can someone give me a step by step for how to get KWord to merge data
from a Kexi database file?
____________________________________
koffice mailing list
koffice@...
To unsubscribe please visit:
https://mail.kde.org/mailman/listinfo/koffice

Re: Merge data from Kexi to KWord

by Jaroslaw Staniek-2 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

John Jason Jordan said the following, On 2008-02-11 07:37:

> I can't get it to work.
>
> I go into Tools > Configure Mail Merge > Open Existing, and in the
> popup I select Qt-SQL Source (power user) - which is the only choice -
> and then I click on OK.
>
> This gives me another popup asking for Hostname, Driver, Database name,
> Username and Port. I enter the name of the computer (Devil7), leave the
> driver at QMYSQL3 (the only option), drag the database file from
> Nautilus into the Database Name box (the filename appears correctly),
> enter my username (jjj), and leave the Port at "default."
>
> When I click on OK, I am prompted for the password, so I enter the root
> password. And then I get "Can't connect to MySQL server on
> 'Devil7' (111)."
>
> I suspect that putting "Devil7" in the top box is wrong, but I can't
> find anything in the Help files that explains where to tell KWord to
> look for the file. The file is right here on the same computer as KWord
> - not on a networked server somewhere.

IIRC, this feature has been added long before Kexi appeared.

Kexi's is not QtSQL-based, the KWord's feature is not dependent on whether the
database was created usign Kexi or not. Your problem can be related to
connection itself. Why do you use nautilus in the procedure or enter uppercase
computer name? Try entering IP address or locelhost if the database is put on
the same computer.

and try to test:
mysql -h {IP} -u root -p

> Can someone give me a step by step for how to get KWord to merge data
> from a Kexi database file?

Exprort to CSV from Kexi, then paste or insert the file. Kexi also ofers a
Python plugin for exporting tables to html, which could be imported too.

For Kexi 2 there's a plan for more direct embedding of query results in other
KDE apps.

--
regards / pozdrawiam, Jaroslaw Staniek
  Sponsored by OpenOffice Polska (http://www.openoffice.com.pl/en) to work on
  Kexi & KOffice (http://www.kexi.pl/en, http://www.koffice.org/kexi)
  KDE Libraries for MS Windows (http://windows.kde.org)
____________________________________
koffice mailing list
koffice@...
To unsubscribe please visit:
https://mail.kde.org/mailman/listinfo/koffice

Re: Merge data from Kexi to KWord

by John Jason Jordan-2 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

On Mon, 11 Feb 2008 10:12:04 +0100
Jaroslaw Staniek <js@...> dijo:

> John Jason Jordan said the following, On 2008-02-11 07:37:
> > I go into Tools > Configure Mail Merge > Open Existing, and in the
> > popup I select Qt-SQL Source (power user) - which is the only choice -
> > and then I click on OK.
> >
> > This gives me another popup asking for Hostname, Driver, Database name,
> > Username and Port. I enter the name of the computer (Devil7), leave the
> > driver at QMYSQL3 (the only option), drag the database file from
> > Nautilus into the Database Name box (the filename appears correctly),
> > enter my username (jjj), and leave the Port at "default."
> >
> > When I click on OK, I am prompted for the password, so I enter the root
> > password. And then I get "Can't connect to MySQL server on
> > 'Devil7' (111)."
> >
> > I suspect that putting "Devil7" in the top box is wrong, but I can't
> > find anything in the Help files that explains where to tell KWord to
> > look for the file. The file is right here on the same computer as KWord
> > - not on a networked server somewhere.

> IIRC, this feature has been added long before Kexi appeared.

Which feature do you mean?

> Kexi's is not QtSQL-based, the KWord's feature is not dependent on whether the
> database was created usign Kexi or not. Your problem can be related to
> connection itself. Why do you use nautilus in the procedure or enter uppercase
> computer name? Try entering IP address or locelhost if the database is put on
> the same computer.
>
> and try to test:
> mysql -h {IP} -u root -p

I get the error message "Can't connect to local MySQL server through
socket '/var/run/mysqld/mysqld.sock' (2)." I get this error message
whether I try to connect via KWord (Tools > Configure Mail Merge), or
using the command line you gave me above.

As for why I used Nautilus, it was just a fast way to type the filename
into the box in the KWord connection window. The Kexi file is
named /home/jjj/REPI/QuestionBank_kexi.kexi. I got tired of typing it
over and over again and found that the filename and path are inserted
automatically if I just drag the file from a Nautilus window into the
box. Besides, it eliminates typos.

> > Can someone give me a step by step for how to get KWord to merge data
> > from a Kexi database file?
>
> Exprort to CSV from Kexi, then paste or insert the file. Kexi also ofers a
> Python plugin for exporting tables to html, which could be imported too.

I can export from Kexi as .csv files, but the database has 43 tables in
it. Doing them one at a time would be painful. Furthermore, I never
want to merge an entire table, so I use queries to select specific
records from the 43 tables and place them into another table called
"Worktable." "Worktable" is what I want to merge from, but the data in
it will always be changing. Furthermore, most of the tables have 25+
fields but I want only selected fields, not the entire table. Pasting
an entire table into a KWord document is not a solution.

> For Kexi 2 there's a plan for more direct embedding of query results in other
> KDE apps.

So at this time KWord cannot connect to data in Kexi?

Thanks for the suggestions. Still trying to figure out how to merge
selected data into a word processor. I'd actually prefer to merge into
OpenOffice.org Writer, but I tried KWord because OOo cannot merge data
from Kexi either. I thought it might be easier using a KDE app like
KWord.
____________________________________
koffice mailing list
koffice@...
To unsubscribe please visit:
https://mail.kde.org/mailman/listinfo/koffice

Re: Merge data from Kexi to KWord

by Jaroslaw Staniek-2 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

John Jason Jordan said the following, On 2008-02-12 04:13:

> On Mon, 11 Feb 2008 10:12:04 +0100
> Jaroslaw Staniek <js@...> dijo:
>
>> John Jason Jordan said the following, On 2008-02-11 07:37:
>>> I go into Tools > Configure Mail Merge > Open Existing, and in the
>>> popup I select Qt-SQL Source (power user) - which is the only choice -
>>> and then I click on OK.
>>>
>>> This gives me another popup asking for Hostname, Driver, Database name,
>>> Username and Port. I enter the name of the computer (Devil7), leave the
>>> driver at QMYSQL3 (the only option), drag the database file from
>>> Nautilus into the Database Name box (the filename appears correctly),
>>> enter my username (jjj), and leave the Port at "default."
>>>
>>> When I click on OK, I am prompted for the password, so I enter the root
>>> password. And then I get "Can't connect to MySQL server on
>>> 'Devil7' (111)."
>>>
>>> I suspect that putting "Devil7" in the top box is wrong, but I can't
>>> find anything in the Help files that explains where to tell KWord to
>>> look for the file. The file is right here on the same computer as KWord
>>> - not on a networked server somewhere.
>
>> IIRC, this feature has been added long before Kexi appeared.
>
> Which feature do you mean?

Tools > Configure Mail Merge; it's not related to Kexi in any explicit way.

>> Kexi's is not QtSQL-based, the KWord's feature is not dependent on whether the
>> database was created usign Kexi or not. Your problem can be related to
>> connection itself. Why do you use nautilus in the procedure or enter uppercase
>> computer name? Try entering IP address or locelhost if the database is put on
>> the same computer.
>>
>> and try to test:
>> mysql -h {IP} -u root -p
>
> I get the error message "Can't connect to local MySQL server through
> socket '/var/run/mysqld/mysqld.sock' (2)." I get this error message
> whether I try to connect via KWord (Tools > Configure Mail Merge), or
> using the command line you gave me above.
>
> As for why I used Nautilus, it was just a fast way to type the filename
> into the box in the KWord connection window. The Kexi file is
> named /home/jjj/REPI/QuestionBank_kexi.kexi. I got tired of typing it
> over and over again and found that the filename and path are inserted
> automatically if I just drag the file from a Nautilus window into the
> box. Besides, it eliminates typos.

.kexi files are SQLite files. This is completely different thing compared to
mysql databases and their server names. Unless KWord 1.x can open SQLite
format (usign QtSQL), you cannot type .kexi filename into KWord Mailmerge's
input box.

>>> Can someone give me a step by step for how to get KWord to merge data
>>> from a Kexi database file?
>> Exprort to CSV from Kexi, then paste or insert the file. Kexi also ofers a
>> Python plugin for exporting tables to html, which could be imported too.
>
> I can export from Kexi as .csv files, but the database has 43 tables in
> it. Doing them one at a time would be painful. Furthermore, I never
> want to merge an entire table, so I use queries to select specific
> records from the 43 tables and place them into another table called
> "Worktable." "Worktable" is what I want to merge from, but the data in
> it will always be changing. Furthermore, most of the tables have 25+
> fields but I want only selected fields, not the entire table. Pasting
> an entire table into a KWord document is not a solution.

Couldn't you run a query within Kexi to limit your set of records?

>> For Kexi 2 there's a plan for more direct embedding of query results in other
>> KDE apps.
>
> So at this time KWord cannot connect to data in Kexi?

You should be able - by connecting to native database (raw tables) on top of
which Kexi is operating. Either SQLite, PostgreSQL or MySQL. Always be
providing proper conenction data - again - without mixing kexi database file
path with server database name.

> Thanks for the suggestions. Still trying to figure out how to merge
> selected data into a word processor. I'd actually prefer to merge into
> OpenOffice.org Writer, but I tried KWord because OOo cannot merge data
> from Kexi either. I thought it might be easier using a KDE app like
> KWord.

--
regards / pozdrawiam, Jaroslaw Staniek
  Sponsored by OpenOffice Polska (http://www.openoffice.com.pl/en) to work on
  Kexi & KOffice (http://www.kexi.pl/en, http://www.koffice.org/kexi)
  KDE Libraries for MS Windows (http://windows.kde.org)
____________________________________
koffice mailing list
koffice@...
To unsubscribe please visit:
https://mail.kde.org/mailman/listinfo/koffice

Re: Merge data from Kexi to KWord

by Martin Atukunda-2 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

On Mon, February 11, 2008 9:37 am, John Jason Jordan wrote:
> I can't get it to work.
>
> I go into Tools > Configure Mail Merge > Open Existing, and in the popup
I select Qt-SQL Source (power user) - which is the only choice - and
then I click on OK.
>
> This gives me another popup asking for Hostname, Driver, Database name,
Username and Port. I enter the name of the computer (Devil7), leave the
driver at QMYSQL3 (the only option), drag the database file from
Nautilus into the Database Name box (the filename appears correctly),
enter my username (jjj), and leave the Port at "default."
>
> When I click on OK, I am prompted for the password, so I enter the root
password. And then I get "Can't connect to MySQL server on
> 'Devil7' (111)."
>
> I suspect that putting "Devil7" in the top box is wrong, but I can't
find anything in the Help files that explains where to tell KWord to
look for the file. The file is right here on the same computer as KWord
- not on a networked server somewhere.
>
> Can someone give me a step by step for how to get KWord to merge data
from a Kexi database file?

Hi, please install the libqt3-mt-sqlite package (or its equivalent).

- Martin -

--
Tech companies need to stay focused on four things: Quality, Consistency,
Innovation and Trust.




____________________________________
koffice mailing list
koffice@...
To unsubscribe please visit:
https://mail.kde.org/mailman/listinfo/koffice
LightInTheBox - Buy quality products at wholesale price