Column will make the table too large (>15000)

Adding a field to a file in the dct, the message “column will make the table too large (>15000)” pops up.

Im curious what people do in this situation.

Do some create a new table/file and link it to the first on a 1:1 relationship or something else?

Tia

Is this a TPS file?

Check if you have any large string or cstring fields that could be moved out of the record buffer into a memo or blob.

A 1:1 is an option but more work.

Cheers

Geoff

Its TPS atm but will be ms sql express or sql lite at a later date.

Whilst a memo could be an option theres alot of fields recording string data which isnt particularly sizeable typically less than <100 but could be upto 512 chars.

Im doing a 1:1 atm but just wanted to check if there was anything else besides what you mentioned that could have been an option.

Theres already 70+ 1:M files that have this sort of <100char data offloaded into groups, thats 70+ browses on tabs on display in a form, so a slightly busy window to say the least.

It needs to be entry fields or text boxes so I can add 1 or more buttons next to the fields because the button doesnt look good in the constraints of an EIP list box of sorts and Id rather the user scrolls the whole window rather than a listbox.

Thanks anyway though.

Could JSON in a BLOB be an alternative?

1 Like

Is there some easy way to create a field control from a json in a blob?

It could be but it depends on how flexible it is.

I’ll give it a think because it could save me having to place static field and button controls on a scrolling window.

Is there some easy way to create a field control from a json in a blob?

You’d do it the same as if you got your data from somewhere else, except you’d need to create a use variable to hold the data. JSON is just the vehicle.

I’ll have a think, having some control over the window layout will be required, but I hadnt thought of using json format.

Any reason why json instead of xml?

With my eyes, I prefer to read JSON over XML. It’s simpler, has fewer tags, and is usually smaller.

It’s also easy to manage in JavaScript.

I guess, go with whatever floats the current boat that you’re rowing.

1 Like

I haven’t actually used it except as required by other Capesoft templates, but you could take a look at their MyTable product.

15k is a TPS limit. Each driver has its own limit. From memory MSsql is 8k. Dont recall if SQLite has a limit.

Personally to store a large number of strings i moved them into a blob. Because i was doing that in a number of tables I wrote the MyTable class. I stored them as JSON because i had jFiles, and moving the strings in and out of a queue to JSON was trivial. XML would serve the same purpose, but the Blob would be bigger.

For editing i use a queue, list box, and edit in place. Pretty straight forward.

In my case this was also useful in that the strings could be added to, or removed, without changing the file structure. So that was handy as well.

Downside is that none of these values can be in an index, and any “search” has to be done client side and is slower. [This may chsnge as servers aquire more Json features - like Postgres is getting.]

1 Like

I could build an index like MS does when it audits files and folders on the hard drive for its search facility.

Its a good point about its outside of the db indexes, I’ll have a look round and see what others are doing to index and search xml/json formatted data.

Up until now Ive only considered xml/json as a way to transport/stream data so not considered the indexing aspect.

Depending on exactly what you’re doing… a couple of times I’ve shifted a whole bunch of fields into a child table, one field per row. The field row can also have display params like what type of control, tip, prompt, etc.

It’s not for everything, but if it’s info only type of stuff, or the user keeps wanting additional stuff, this can work really well.