473,796 Members | 2,688 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Is there a limit to sql string length

SJM
In some VBA code I am building an SQL string to append a new record to a
table. The string involves 40 fields. What I am finding is that it works
with 39 fields but when I add 40 it fails with the error 3134 (syntax
error). I am 99% sure there is no syntax error, rather I suspect that it
could be due to limit on string length or number of fields. I have not been
able to find anything that defines this though.

Nov 12 '05 #1
2 12424
"SJM" <1_*********@mo l.mn> wrote in
news:%H******** *******@nnrp1.o zemail.com.au:
In some VBA code I am building an SQL string to append a new record to a
table. The string involves 40 fields. What I am finding is that it works
with 39 fields but when I add 40 it fails with the error 3134 (syntax
error). I am 99% sure there is no syntax error, rather I suspect that it
could be due to limit on string length or number of fields. I have not
been able to find anything that defines this though.


from AcXP help

Access Specifications

**** begin quote ****

Query

Attribute Maximum
Number of enforced relationships 32 per table minus the number of indexes
that are on the table for fields or combinations of fields that are not
involved in relationships Number of tables in a query 32
Number of fields in a recordset 255
Recordset size 1 gigabyte
Sort limit 255 characters in one or more fields
Number of levels of nested queries 50
Number of characters in a cell in the query design grid 1,024
Number of characters for a parameter in a parameter query 255
Number of ANDs in a WHERE or HAVING clause 99
Number of characters in an SQL statement approximately 64,000

**** end quote ****

--
Lyle
(for e-mail refer to http://ffdba.com/contacts.htm)
Nov 12 '05 #2
TC
Sorry, it is 99.99% likely to be a syntax error.

debug.print the "bad" SQL string, & post the result here.

HTH,
TC
"SJM" <1_*********@mo l.mn> wrote in message
news:%H******** *******@nnrp1.o zemail.com.au.. .
In some VBA code I am building an SQL string to append a new record to a
table. The string involves 40 fields. What I am finding is that it works
with 39 fields but when I add 40 it fails with the error 3134 (syntax
error). I am 99% sure there is no syntax error, rather I suspect that it
could be due to limit on string length or number of fields. I have not been able to find anything that defines this though.

Nov 12 '05 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

6
5201
by: Bill | last post by:
I currently have a program that crashes if the sessionid is longer than 9 digits. Is there a way to trim the length of the string that IIS kicks out and limit it to 9 digits, or if that can't be done, is there a function I can use to trim the 10 digit string down to 9 digits? Thanks, Bill
5
12157
by: Jesper Rønn-Jensen | last post by:
I have a textarea that must be limited to 70 characters. No big deal -- at least so I thought. * Textarea must not exceed 70 characters * Exceeding content must be cut off * Must work on input by keyboard (keypress, keyup events) * Must work on pasted input from context menu * Must work on pasted input via CTRL+V and similar * Must work on pasted input via browsers menu>Edit>Paste * Must work in Mozilla + IE and coded via W3C standards
2
21217
by: SJM | last post by:
In some VBA code I am building an SQL string to append a new record to a table. The string involves 40 fields. What I am finding is that it works with 39 fields but when I add 40 it fails with the error 3134 (syntax error). I am 99% sure there is no syntax error, rather I suspect that it could be due to limit on string length or number of fields. I have not been able to find anything that defines this though.
2
1975
by: Tom Dacon | last post by:
I'm raising an event in a component, using ISynchronizeInvoke.Invoke, and my event args object contains a string as one of its members. If the string is longer than 63 bytes, the Invoke call pulls an unhandled exception in System.Windows.Forms.dll, to the effect that the string length must be less than 64. If I trim the string to 31 characters (62 bytes) everything's fine and the event goes as intended. But if the string length is 32 or...
10
3836
by: VM | last post by:
How can I limit the use of the PC's virtual memory? I'm running a process that basically takes a txt file and loads it to a datatable. The problem is that the file is over 400,000 lines long (77 MB) and after a while I get the Windows message saying that the virtual memory's getting really low. Plus the machine gets really sluggish (with multi-threading). Is it possible to use the virtual memory until it reaches a certain limit and then use...
0
1199
by: vadim | last post by:
Hi, Does anybody know if there is limit on the length of string in web.config file? I am particularly interested in appSettings section add key = key value= value, Is there limit on the value length? Can it be 500 or 1000 charcters? Thank you
6
6528
by: Aaron Smith | last post by:
Is there a way to put a limit on the text size of a datagrid column? Thanks, Aaron -- --- Aaron Smith Remove -1- to E-Mail me. Spam Sucks.
0
3456
by: Burton Wilkins | last post by:
Dear Authorities: I realize that in communicating with a Web Service, one is essentially passing a string as a parameter. Is there a limit over the Internet how long a parameter string can be? Or can the string be of an unlimited length, and is then simply divided up into packets? Is there a danger of loosing data if the string being passed in a parameter
5
5441
by: Daniel | last post by:
c# string size limit? length of string limit?
0
9525
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 effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
10452
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, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
1
10169
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 Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
10003
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 protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
9050
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
7546
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 presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
5440
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
5569
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
4115
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system

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.