Brad Scott skrev:
Any line beginning with just a number (ie 9, 10, 16) causes a failure. What am
I missing?
backticks. Use `9`, `10`, etc.
Having column names that begin with numbers is a really bad design
decision. "9a123" (unquoted, of course) will work, as you've noticed,
but e.g. "
Hi Brad,
2010/6/8 Brad Scott :
[...]
> Any line beginning with just a number (ie 9, 10, 16) causes a failure. What
> am I missing?
you should add backticks ( ` ) at both ends of the column name, e.g.
`7c` varchar(255) NOT NULL default '',
I think your export should have been done with the opt
Hi,
James Graham wrote:
Hi List,
We have a transactions table (~600k records). I'm trying a simple update
query, it fails.
I thought this could be due to a reserved word problem, but all names
have been escaped.
mysql> UPDATE `tblTransaction` SET `TYPE` = 'Manual' WHERE (`ORDERID` =
'694215576
I dont think that is the problem but, what do you mean by a slow
connection ?, you cant run the dos2unix command on the remote server ?
The error ocurred on line 2, did you see any special word in that line
? can you share with us that line? , remember that each version may
can reserve different
At 15:19 +0100 7/6/06, Rob Desbois wrote:
With the CHANGE clause of ALTER TABLE statement, you must provide
the column definition, so something like this is what you need:
ALTER TABLE actors CHANGE director_id actor_id MEDIUMINT UNSIGNED NOT NULL;
or whatever your original definition is.
Wo
You can't just change the name without changing (or stating) the type.
ALTER TABLE actors CHANGE director_id actos_id varchar(96) default NULL;
J.R.
-Original Message-
From: Mark Sargent [mailto:[EMAIL PROTECTED]
Sent: Wednesday, June 07, 2006 10:10 AM
To: mysql@lists.mysql.com
Subject:
Mark,
With the CHANGE clause of ALTER TABLE statement, you must provide the column
definition, so something like this is what you need:
ALTER TABLE actors CHANGE director_id actor_id MEDIUMINT UNSIGNED NOT NULL;
or whatever your original definition is.
AFAIK there is no way to rename a column
At 0:09 +1000 8/6/06, Mark Sargent wrote:
ALTER TABLE t2 MODIFY a TINYINT NOT NULL, CHANGE b c CHAR(20);
for changing the name of a column, right? So, why doesn't the below work?
mysql> ALTER TABLE actors CHANGE director_id actor_id;
I'm no great expert myself, but off the top of my head, may
ng Tan Son'" <[EMAIL PROTECTED]>
Sent: Thursday, March 16, 2006 10:51 PM
Subject: RE: Error 1064: update .select nested.
AAAUUUGGGHHH!!! You used the dreaded "comma separated list" !!! ;-)
A more explicit way to write the same thing posted by Sr. Cruz...
upd
AAAUUUGGGHHH!!! You used the dreaded "comma separated list" !!! ;-)
A more explicit way to write the same thing posted by Sr. Cruz...
update TABLE1 a
INNER JOIN TABLE2 b
on a.id = b.other_id
set a.FIELD1=b.FIELD2
WHERE a.column1='literal';
Actually posting a real query (instead of a cl
update TABLE1 a, TABLE2 b set a.FIELD1=b.FIELD2
where column2='[EMAIL PROTECTED]'
And column1 = '[EMAIL PROTECTED]'
Or:
update TABLE1 a, TABLE2 b set a.FIELD1=b.FIELD2
where b.column2=a.column1
And column1 = '[EMAIL PROTECTED]'
Regards!
-Mensaje original-
De: Truong Tan Son [mailto:
Hello.
> FOREIGN KEY (A_areaNum) REFERENCES Area(areaNum),
Put Area in backticks ('`'). See:
http://dev.mysql.com/doc/refman/5.0/en/legal-names.html
Nabegh Al-Thalji wrote:
> When I execute the following query
>
> CREATE TABLE Sponsor (
> sNum INTEGER UNSIGNED NOT NULL,
> sAdr
Hi,
You are using a reserved function name "AREA" (polygon function) as a
fieldname. Simply change the field's name or try using quotes around
it...
Detlev
> [...]
> FOREIGN KEY (A_areaNum) REFERENCES Area(areaNum),
> [...]
> Any ideas?
--
MySQL General Mailing List
For list archives:
Chuzo,
SELECT MAX(LENGTH(...)) FROM ... ought to work.
SQL doesn't allow aggregate funcs like MAX() in the WHERE clause. Use
HAVING().
For nested queries like SELECT ... WHERE colvalue=(SELECT...) you need
version 4.1 or later.
Peter Brawley
http://www.artfulsoftware.com
-
Chuzo Okuda wrote
Hi.
LIMIT clause does not accept negative values.
See:
http://dev.mysql.com/doc/mysql/en/SELECT.html
Leon Sargent <[EMAIL PROTECTED]> wrote:
>
> Good Morning.
>
> I am new to the list and new to Mysql.
>
> I am in the process of running a website and I need a little newbie help.
One of the tricky things about finding errors is that the error is often
earlier than you expect. Mysql points out where it stopped understanding
you, but often it's due to something on the line before. That's the case
here. There's nothing wrong with your ENUM, but the previous line says you
Klaus Neudecker <[EMAIL PROTECTED]> wrote:
> Hi,
> I am comparable new to mySQL, so sorry if I might bother you with a
> newby Problem:
>
> When I connect to the database via phpMyAdmin or via the mySQL Command
> Line Tool as root I have problems creating a view (root has all
> privelegs, and t
Hill, Keith wrote:
I am converting an Access95 DB to mySQL. The interface will remain in Access95. I encountered a problem with one of the existing queries. The code for the query is:
SELECT DISTINCTROW ManualChecksPrinted.AccountNum, ManualChecksPrinted.CheckNumber, ManualChecksPrinted.A
ction with little
modifications.
> - Original Message -
> From: "Sergei Golubchik" <[EMAIL PROTECTED]>
> To: "Gustavo Castro" <[EMAIL PROTECTED]>
> Cc: <[EMAIL PROTECTED]>; "Fortuno, Adam" <[EMAIL PROTECTED]>
> Sent: M
ith little
modifications.
- Original Message -
From: "Sergei Golubchik" <[EMAIL PROTECTED]>
To: "Gustavo Castro" <[EMAIL PROTECTED]>
Cc: <[EMAIL PROTECTED]>; "Fortuno, Adam" <[EMAIL PROTECTED]>
Sent: Monday, September 08, 2003 10:30 PM
Subj
Hi!
On Sep 08, Gustavo Castro wrote:
> Hello,
> i?m using the 3.23.57 version and i?ve declared a native function, but when
> i call it (SELECT GETUPDATE(1);) i
> get this line
>
> ERROR 1064: You have an error in you SQL syntax near '(1)' at line 1;
>
> I think i?ve followed all the steps right
hans,
Tuesday, October 01, 2002, 1:02:02 PM, you wrote:
hp> got a little problem during learning mysql :
hp> have made a file called create_member.sql, looks like this here :
hp> CREATE TABLE member
hp> {
hp> last_name VARCHAR(20) NOT NULL,
hp> first_name VARCHAR(20) NOT NULL,
hp
That's what I used :
mysql testdb < exp. Sorry about the typo
Gene
--- Gerald Clark <[EMAIL PROTECTED]>
wrote:
>
>
> Gene Gurevich wrote:
>
> > Hi all:
> >
> > I'm trying to import the tables from the dump file
> > via
> >
> > mysqldump testdb < exp
>
> That should be:
>
> mysql testdb
Gene Gurevich wrote:
> Hi all:
>
> I'm trying to import the tables from the dump file
> via
>
> mysqldump testdb < exp
That should be:
mysql testdb < exp
>
> and it complaints about the command in the export
> file:
> DROP TABLE IF EXISTS db;
> CREATE TABLE db (
> Host char(60) NOT N
24 matches
Mail list logo