Welcome to the dBforums forums.

You are currently viewing our boards as a guest which gives you limited access to view most discussions, articles and access our other FREE features. By joining our free community you will have access to post topics, communicate privately with other members (PM), respond to polls, upload your own photos and access many other special features. Registration is fast, simple and absolutely free so please, join our community today!

If you have any problems with the registration process or your account login, please contact contact support.

If you prefer not to see double-underlined words and corresponding ads, place your cursor
here for ContentLink opt out.

Go Back  dBforums > Database Server Software > MySQL > limit to length of an sql statement

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old 07-09-03, 07:56
MarionMck MarionMck is offline
Registered User
 
Join Date: Jul 2003
Posts: 3
limit to length of an sql statement

Does MySQL impose a limit to the length of an sql statement?

I seem to be hitting a limit of 255 characters. Can this be changed?
Reply With Quote
  #2 (permalink)  
Old 07-09-03, 08:25
omiossec omiossec is offline
Registered User
 
Join Date: Jan 2003
Location: Paris, France
Posts: 320
Re: limit to length of an sql statement

Quote:
Originally posted by MarionMck
Does MySQL impose a limit to the length of an sql statement?

I seem to be hitting a limit of 255 characters. Can this be changed?


There no limit like this (255 char) perhaps this is your tool that make the limit
__________________
Olivier Miossec
--
http://www.lasso-developpeur.net/
--
Reply With Quote
  #3 (permalink)  
Old 07-09-03, 08:39
MarionMck MarionMck is offline
Registered User
 
Join Date: Jul 2003
Posts: 3
Re: limit to length of an sql statement

If I use the command line tool mysql.exe, it seems to block key entry after 254 characters. I was originally doing the query via JDBC and this also seemed to fail, which was why I was trying it in the command line tool.

The query I am doing is quite complex - it must be failing for a different reason. The query is

select date_format(xx_start, '%d %b %Y %H:%i'), xx_userid, xx_link, date_format(xx_due_date, '%d %b %Y %H:%i'), xx_synopsis, xx_workflowid, xx_tasks.xx_taskid, xx_tasks.xx_elementid, xx_tasks.xx_cdocid
from xx_tasks, xx_task_recipients
where ( xx_tasks.xx_workflowid = '1012858233' ) and xx_tasks.xx_taskid = xx_task_recipients.xx_taskid and xx_completedby = null

I will split it up and check it in the command line tool.
Reply With Quote
  #4 (permalink)  
Old 07-09-03, 08:45
MarionMck MarionMck is offline
Registered User
 
Join Date: Jul 2003
Posts: 3
Re: limit to length of an sql statement

Oops! Sorry, should be 'is null' rather than '= null'.

The command line tool was hitting the limit without keying 'return' to build up a single query.

Thanks for your input - it's stopped me going off on the wrong track!
Reply With Quote
  #5 (permalink)  
Old 07-09-03, 22:37
hmaldonado hmaldonado is offline
Registered User
 
Join Date: Jun 2003
Location: México
Posts: 5
Re: limit to length of an sql statement

Maybe you should change to phpMySQL is a any web-base tool to manage a MySQL server.

www.phpmyadmin.net
Reply With Quote
Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

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

vB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On