473,398 Members | 2,212 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,398 software developers and data experts.

What is the maximum query length in postgresql?

If I want to generate dynamically some queries in a php 5 application to retrieve information from an postgresql database. is there a maximum length for this query?

When i use the IN statement, how many values can I use in?
Oct 18 '10 #1
3 7619
rski
700 Expert 512MB
I don't think there is a query length limit, I did't hear about it. Did you meet any problems with such 'big' IN statement
Oct 20 '10 #2
In Oracle database the maximum size of SQL statement is
about 4000 characters, I want to know what about PostgreSQL
(of course it more more than 4000 characters, but is there any
number for the max size of a query?

thanks a lot.
Oct 21 '10 #3
rski
700 Expert 512MB
In postgres source code there are lots of statements where query text (sourceText) is defined as 'const char *', see below
Expand|Select|Wrap|Line Numbers
  1. static void
  2. ProcessQuery(PlannedStmt *plan,
  3.               const char *sourceText,
  4.               ParamListInfo params,
  5.               DestReceiver *dest,
  6.               char *completionTag)
  7.  
So I assume that max query lenght is not 'hard coded'
Nov 14 '10 #4

Sign in to post your reply or Sign up for a free account.

Similar topics

4
by: Joe Goh | last post by:
Hi there Does anyone know what is the maximum column length for a table in a MySQL database? I was thinking of storing feedback in the form of text in the database. How feasible is this? Would...
2
by: Dmitri Shvetsov | last post by:
Hi All, Does somebody know what's the length's ratio in we convert byte to base64 string? Is it a constant ratio or it can be different from case to case? For example if I convert a byte array...
2
by: Jacky Kwok | last post by:
Dear all: I know how to use the "Application_Error" in "Global.asax" to catch the exception and display my own error message page. However, I found "Application_Error" cannot handle the error...
11
by: Chris Hayes | last post by:
Greetings, I have an ASP.NET page that accepts input from an HtmlInputFile object. I have set the maximum size for HttpRequests to 2MB in the web.config file. And now I am trying to CATCH...
0
by: Chris Hayes | last post by:
I've seen that when an HTTP 400 error occurs ("Maximum request length exceeded") that some of my Session level variables and Cookies get "lost" is there a way to preserve them without resorting to...
2
by: Lloyd Dupont | last post by:
I'm experimenting with an upload file page. I have a few HtmlInputFile on it. While testing it, I selected a 12MBfile, click "upload". I was think I am safe as (at last in the code) I don't...
3
by: =?Utf-8?B?UGV0ZXIgU2NobWl0eg==?= | last post by:
HI, in one of my webservices I need to provide a string to the consuming application that can become really large (depending on user input). Unfortunately, if the string becomes too long, the...
1
by: Mike P | last post by:
What is the maximum cell length in Excel 2000? I am writing a large text field to Excel and it seems to break it up into different cells after about 400 characters and then breaks everything...
5
toxicpaint
by: toxicpaint | last post by:
Hi, I'm sure there is a really easy way to do this and I'm just being silly, but is there a way that I can get a text box to stop people typing when it hits its maximum character length. I've...
1
by: hergele | last post by:
Hello all.. I am trying to convert an application which is working on Oracle to postgreSql.. I've seen a query in code something like this... select * from table1 a1 , table1 a2, table2 a3, ...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.