Re: CREATE TABLE / Telnet (Linux / Unix server)

2001-02-12 Thread Joel Holtzman

I turned my access db into excel, and into .csv

So that's the structure of my text file. When I use "Load data infile..."
I get the 10 warnings. 10 for the 2 columns, and 8 records. Does it have to
be a special format? I have the file.txt on the server. I can point to it. I
just can't get it to insert this file's records. Are you saying when columns
exist in a db, you must use Select into?

And does the file need to have columns/records sepearated a certain way?
Mine uses commas. (.csv file)

Thanks

Joel


- Original Message -
From: Rus [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Monday, February 12, 2001 1:21 AM
Subject: Re: CREATE TABLE / Telnet (Linux / Unix server)



 Check the structure of txt file. Does it created with SELECT ... INTO
 OUTFILE? Check command syntax.

 - Original Message -----
 From: Joel Holtzman [EMAIL PROTECTED]
 To: Nielsen [EMAIL PROTECTED]
 Cc: [EMAIL PROTECTED]
 Sent: Monday, February 12, 2001 8:51 AM
 Subject: Re: CREATE TABLE / Telnet (Linux / Unix server)


  I've had questions about this too. What happens if I have a primary key,
 and
  the text file has the columns that are in the existing table, with
 records.
  And I want to insert them. How do I get rid of that duplicate error? I
 read
  the manual, about 'ignore' but I can't get it to work.
 
  Any ideas?
 
  In other words, if I have a db with one table "Test" and columns:
  A B
 
  And my file.txt has the columns and records, so it's structured like
this:
  A B
  1  2
  3 4
 
  So when I 'load data infile file.txt' the db with 'test' table and 0
  records, becomes table with records added.
 
  How do I avoid errors. The manual is no help, I tried it. Any ideas?
 SHould
  I ignore the Primary key field in the text file, and use the rest of it
to
  avoid that duplicate error? The text file is separated by tabs.
 
  Thanks
 
  Joel
 
 
  - Original Message -
  From: Nielsen [EMAIL PROTECTED]
  To: C.o.m.b.u.s.t. [EMAIL PROTECTED];
  [EMAIL PROTECTED]
  Sent: Sunday, February 11, 2001 9:24 PM
  Subject: RE: CREATE TABLE / Telnet (Linux / Unix server)
 
 
...and this will load the table into your database.  Now, in the
book
it doesn't specify whether or not you have to be on the computer
with
the server, or if you can send the .sql file command from your
computer to the remote server, sort of like a file transfer protocol
as well.  Basically, my question is, do I have to either FTP my
files
to the server, and then execute the command, or can I do it remotely
without FTP? Or is it possible AT ALL to execute the command from a
remote computer?  In case it helps, I am on a Windows 98 system
connected through SSH to an Linux system running Apache.  Please
help, I'm stuck and I won't give up until I'm un-stuck!  Thanks in
advance to all that reply.
  
   The file must be on the remote machine (as has been answered), but
yes,
 if
  you
   are connected to the shell (via telnet/ssh/ssh2/etc), you can execute
 the
   command.  And, no, the extension may be anything (all you're doing is
   redirecting the contents of the file (via '') into the 'mysql
 database'
   command.
  
   HTH,
  
   Jon A. Nielsen.
  
  
   -
   Before posting, please check:
  http://www.mysql.com/manual.php   (the manual)
  http://lists.mysql.com/   (the list archive)
  
   To request this thread, e-mail [EMAIL PROTECTED]
   To unsubscribe, e-mail
  [EMAIL PROTECTED]
   Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php
  
  
 
 
  -
  Before posting, please check:
 http://www.mysql.com/manual.php   (the manual)
 http://lists.mysql.com/   (the list archive)
 
  To request this thread, e-mail [EMAIL PROTECTED]
  To unsubscribe, e-mail
 [EMAIL PROTECTED]
  Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php
 
 





 -
 Before posting, please check:
http://www.mysql.com/manual.php   (the manual)
http://lists.mysql.com/   (the list archive)

 To request this thread, e-mail [EMAIL PROTECTED]
 To unsubscribe, e-mail
[EMAIL PROTECTED]
 Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php




-
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/   (the list archive)

To request this thread, e-mail [EMAIL PROTECTED]
To unsubscribe, e-mail [EMAIL PROTECTED]
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php




Re: CREATE TABLE / Telnet (Linux / Unix server)

2001-02-11 Thread Joel Holtzman

I've had questions about this too. What happens if I have a primary key, and
the text file has the columns that are in the existing table, with records.
And I want to insert them. How do I get rid of that duplicate error? I read
the manual, about 'ignore' but I can't get it to work.

Any ideas?

In other words, if I have a db with one table "Test" and columns:
A B

And my file.txt has the columns and records, so it's structured like this:
A B
1  2
3 4

So when I 'load data infile file.txt' the db with 'test' table and 0
records, becomes table with records added.

How do I avoid errors. The manual is no help, I tried it. Any ideas? SHould
I ignore the Primary key field in the text file, and use the rest of it to
avoid that duplicate error? The text file is separated by tabs.

Thanks

Joel


- Original Message -
From: Nielsen [EMAIL PROTECTED]
To: C.o.m.b.u.s.t. [EMAIL PROTECTED];
[EMAIL PROTECTED]
Sent: Sunday, February 11, 2001 9:24 PM
Subject: RE: CREATE TABLE / Telnet (Linux / Unix server)


  ...and this will load the table into your database.  Now, in the book
  it doesn't specify whether or not you have to be on the computer with
  the server, or if you can send the .sql file command from your
  computer to the remote server, sort of like a file transfer protocol
  as well.  Basically, my question is, do I have to either FTP my files
  to the server, and then execute the command, or can I do it remotely
  without FTP? Or is it possible AT ALL to execute the command from a
  remote computer?  In case it helps, I am on a Windows 98 system
  connected through SSH to an Linux system running Apache.  Please
  help, I'm stuck and I won't give up until I'm un-stuck!  Thanks in
  advance to all that reply.

 The file must be on the remote machine (as has been answered), but yes, if
you
 are connected to the shell (via telnet/ssh/ssh2/etc), you can execute the
 command.  And, no, the extension may be anything (all you're doing is
 redirecting the contents of the file (via '') into the 'mysql database'
 command.

 HTH,

 Jon A. Nielsen.


 -
 Before posting, please check:
http://www.mysql.com/manual.php   (the manual)
http://lists.mysql.com/   (the list archive)

 To request this thread, e-mail [EMAIL PROTECTED]
 To unsubscribe, e-mail
[EMAIL PROTECTED]
 Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php




-
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/   (the list archive)

To request this thread, e-mail [EMAIL PROTECTED]
To unsubscribe, e-mail [EMAIL PROTECTED]
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php




Simple datatype question

2001-02-08 Thread Joel Holtzman

Hello, I'm looking at the manual, and I cannot find the answer to this simple question.

What is the datatype in mysql for boolean? In Access it's yes/no.

What about mysql?

Thanks

Joel



Simple question

2001-02-05 Thread Joel Holtzman

Hello, I always wanted a gui interface to use on my win 98 pc to connect to mysql, and 
create/edit tables. However, i always get an access denied error, saying I'm not 
allowed to connect to the mysql server. 

However, via telnet, I am fine.

The support for the software sucks, and all the other programs I have tried suck, 
don't work, or are in german.

What gui interface is good to connect to a mysql server to create/edit db's/tables, 
and if you use it, how in the world do you connect?

I can connect to the server via telnet. Just fine. But via the software, I get 
permission denied. Any way I can set it up on my server to allow such a connection out 
of telnet? 

Thanks

Joel



Data won't display

2001-02-04 Thread Joel Holtzman

Hello, I noticed that while access databases use 'memo' mysql does not. It
uses blob. Anyway, I used it for a discussion board, and it stores messages,
but it won't display on my web page via asp.

It would work via access using 'memo' not 'text'.

So what conditions apply when inserting/displaying 'blob' text ( I need text
well over 1 characters I figure at times) that I should know about?

Anybody notice how text records sometimes don't display?

Thanks




-
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/   (the list archive)

To request this thread, e-mail [EMAIL PROTECTED]
To unsubscribe, e-mail [EMAIL PROTECTED]
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php




Load Data question

2001-02-03 Thread Joel Holtzman

Hello, what is the correct syntax forignore?

I have a table with columsn already put in, and primary key has 0 as value.

When I do "load data infil 'file.txt'...

it gives a duplicate error. Documentation says to use 'ignore'. But I can't get it to 
work.

What is the *correct* syntax to load a file with columns to *overwrite* what I have in 
a table? It would make life easier as all the 'gui' software is either confusing, in 
another language, or doesn't work.

Thanks





Deleting table question...

2001-02-02 Thread Joel Holtzman

Hello, via telnet with mysql server on linux, I try to delete a table, but it won't 
work. I'm browsing the documentation, I can't see what will work. I can do this via 
asp, but I'd love to know the command for something that should be as simple as

mysql Delete (tablename) from (Database name);

Anybody?

Thanks

PS. Sorry if this sounds basic, I thought it was, but nothing works.



Re: Deleting table question...

2001-02-02 Thread Joel Holtzman

Thank you, I learned that I needed:

Drop *table* tablename

Thanks for your help, guys. I appreciate it

Joel


- Original Message -
From: [EMAIL PROTECTED]
To: Joel Holtzman [EMAIL PROTECTED]
Cc: [EMAIL PROTECTED]
Sent: Friday, February 02, 2001 3:51 PM
Subject: Re: Deleting table question...


 why dont you try

 use database
 drop tablename

 Mensaje citado por: Joel Holtzman [EMAIL PROTECTED]:

  Hello, via telnet with mysql server on linux, I try
  to delete a table, but it won\'t work. I\'m browsing
  the documentation, I can\'t see what will work. I can
  do this via asp, but I\'d love to know the command
  for something that should be as simple as
 
  mysql Delete (tablename) from (Database name);
 
  Anybody?
 
  Thanks
 
  PS. Sorry if this sounds basic, I thought it was,
  but nothing works.
 

 -
 Before posting, please check:
http://www.mysql.com/manual.php   (the manual)
http://lists.mysql.com/   (the list archive)

 To request this thread, e-mail [EMAIL PROTECTED]
 To unsubscribe, e-mail
[EMAIL PROTECTED]
 Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php




-
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/   (the list archive)

To request this thread, e-mail [EMAIL PROTECTED]
To unsubscribe, e-mail [EMAIL PROTECTED]
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php




Load Data errors

2001-02-02 Thread Joel Holtzman

Hello, I have one question about the 'load data' function.

Below is the what I have for 'actor.txt' for a text file I want to load to table 
'actor'


| ID  |   fFirst   |   Last   
---
| 2   | Sean|  Smith  
---
| 5   |   John   |  Jones

The columns ID/FIRST/LAST already exist. I just want to overight the data
with this file. But when I do, I get an error :

duplicate entry for key 1 (I guess that's the primary key, which is ID)

Basically, the question is if I can ever just either:

A.) Create a table and with the create synatx, use load data infile. Otherwise, I am 
forced to create default values, and when I use load data infile after, I get 
duplicate errors

OR

B.) Is there a way to overright the data of the table? When I create a table, there 
are 0 records entered. That's why I use these text files. Yet, somehow, it won't be 
inserted. The documentation only shows the syntax, not the solution.

Has anybody had experienced going around this issue? I've tried to no avail. Even the 
gui software people rave about give me errors. But this is my priority, I am sure it's 
something simple.

Thanks for your time. I thought I'd ask to play it safe as I search for answers.

Joel