LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Non-*NIX Forums > Programming
User Name
Password
Programming This forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.

Notices


Reply
  Search this Thread
Old 09-30-2004, 04:54 AM   #1
suchi_s
Member
 
Registered: May 2004
Posts: 133

Rep: Reputation: 15
error with the code


mysql -e 'update jalalarm set utime='2005-12-6" 18\:00\:00"' ' -u root -pmysql tgc

Unknown command '\:'
how to overcome
 
Old 09-30-2004, 05:46 AM   #2
Hko
Senior Member
 
Registered: Aug 2002
Location: Groningen, The Netherlands
Distribution: Debian
Posts: 2,536

Rep: Reputation: 111Reputation: 111
There's complex quoting in your statement: escaped ': ' within double quotes, which are within single quotes within yet another set of single quotes. Probably the problem is in the quoting / escaping.

Do you really need the '\' in front of the ':' ? It's already within quotes.

What exactly do you want to do with: set utime='2005-12-6" 18\:00\:00"'

Try first to put your SQL command in a file instead of on the command line, and execute it with:
mysql -u root -pmysql tgc <file-with-sql.txt

Try at first to use as little quoting/escaping as possible, and add them as needed.
 
Old 09-30-2004, 05:48 AM   #3
suchi_s
Member
 
Registered: May 2004
Posts: 133

Original Poster
Rep: Reputation: 15
update jalbk set utime = '2004-09-27 18:00:00' where sdate < '2004-03-15 18:00:00';
i m writting this code in a file and then executing
not working
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
C code 'gets' error boxerboy Programming 6 08-28-2005 03:27 PM
User Preferences: Use HTML code instead of vB code? (vB code is overrated) stefanlasiewski LQ Suggestions & Feedback 5 07-26-2005 01:37 AM
LPRng error 'NONZERO RFC1179 ERROR CODE FROM SERVER' ivanscheers Linux - Networking 0 10-11-2004 02:50 AM
C code error shams Programming 2 07-07-2004 09:42 PM
Synaptic error: "sub-process /usr/bin/dpkg returned an error code (2)" firefly2442 Linux - Software 3 02-04-2004 06:41 PM

LinuxQuestions.org > Forums > Non-*NIX Forums > Programming

All times are GMT -5. The time now is 04:36 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration