Le 16/03/2016 21:19, Ian "Witty" Whitfield a écrit :

Hi Ian,

> 
> My needs are to have a SOLID, RELIABLE simple Members Database that does
> not crash all the time and take the data with it as well.
> I don't even need a RDB as I have one table, one Form and a few queries,
> it is single user on a single machine. My Form only uses Text Boxes,
> Drop-Down Boxes, Check Boxes and Photos and Graphics. End of story!! i
> don't want to become a DB expert just a basic layout person and every
> day user.


Apologies if I appear rude, but then really, you should be installing
Wine, or PlayonLinux, and Lotus Approach or an old version of FileMaker
Pro, and using that instead.

> 

> January, (Data lost, as is common, even with MySQL. The file is still
> there but it can not be accessed).

Without more detail, as to what you lost, in my experience your loss of
data in mysql likely had no direct link of cause and effect between Base
(a few exceptions notwithstanding) and the underlying database. Most
causes of loss of mysql data are linked to table corruption in MyISAM
tables (which personally I have found exceptionally rare - once in 15
years of use), incorrect backup and restoration techniques, and plain
user error (i.e. trying to force mysql to accept data in fields that
were not designed for it). Again, nothing to do with LO Base per se, but
rather lack of understanding of how a mysql server and database
functions. This lack of understanding can only be compensated for by
reading the specific mysql documentation, of which there is a plethora,
and yes, it means investing time. If, as you indicate, you don't want to
spend that time, which I can understand, then maybe you shouldn't really
be using mysql as your database provider.


> So Alexander has told me how to save my Form (that helps a lot) and I
> decided to get back into Base as it seems to be the only way to go for
> me. But MySQL is giving me up-hill. It does not seem to want to save an
> empty Table for me to import my CSV into and gives me this error ...

Again, I don't understand why you are attempting to use LO and a CSV
file to import your data into your mysql database.


> 
> "#1064 - You have an error in your SQL syntax; check the manual that
> corresponds to your MySQL server version for the right syntax to use
> near 'varchar(10), `NULL` varchar(10), `NULL` varchar(10), `NULL`
> varchar(21), `NULL` ' at line 1"

Without the corresponding table definition, and the particular string of
data you are trying to insert into the table, the above error means
nothing to us. All that it tells us is that the insert failed because
either the INSERT query statement is wrong, or else the data that you
are trying to insert doesn't match the definition of the fields of your
table at some particular place.

If you are trying to copy the data from a CSV file that you opened in LO
by dragging and dropping on your empty table link in your ODB file, then
there could indeed be an additional problem of the copy wizard
interpeting the data values incorrectly and setting them as something
which doesn't fit the mysql table definition. Date strings, time
strings, autoincrement fields, integer values in an unsigned INT field,
booleans, etc, all of these can potentially be misrepresented when one
opens them from a CSV in LO and then tries to insert them into a mysql
table.

My recommendation is, as I wrote previously in another thread of yours,
to use the mysql command line to import the data from your CSV file.

You do this by reading a tutorial or the fine manual :

http://www.mysqltutorial.org/import-csv-file-mysql-table/

or

http://dev.mysql.com/doc/refman/5.7/en/load-data.html


Alex




-- 
To unsubscribe e-mail to: [email protected]
Problems? http://www.libreoffice.org/get-help/mailing-lists/how-to-unsubscribe/
Posting guidelines + more: http://wiki.documentfoundation.org/Netiquette
List archive: http://listarchives.libreoffice.org/global/users/
All messages sent to this list will be publicly archived and cannot be deleted

Reply via email to