Jump to content

Several database functions in one table cell

Recommended Posts

Is it possible to place a formula with several database functions in a single cell?  And even add a fixed text?

For example, for plants, can we group these two cells into one? Instead of having :
A1 : =('Plant Record'.'Botanical name')
A2: ='Plant Record'.'Remark 1'.

Have something like this :

A3: ==('Plant Record'.'Botanical name') ????  ('Plant Record'.'Remark 1')

Thanks a lot!

Link to comment

Not sure about combining the functions but what you can do is use concat to combine the data from two (or more) columns into one e.g. put =concat(A2,B2) in C2 then collapse columns A2 + B2 to hide them.


Use =concat(A2, ' ', B2) if you want a space in between or =concat(A2, ' , ', B2) if you want a comma, etc.

Link to comment

Maybe post a file or at least some screenshots. It works for me. But maybe I'm totally misunderstanding what you're asking for. You have a file with Plants in it + a database report which is returning data from those Plants right? You have the 'botanical name' field of the plant record being returned in one column + the 'remark 1' field being returned in another column yes? If so you can use concat to combine those two columns into a single third column + add additional text or punctuation in the process then hide the original two columns.

Link to comment

And yes, it works!  By making a small file to send here, I redid the test and it works perfectly.
I probably made a syntax error on my first try.
Thanks a lot!


While I'm at it: can I insert a "line feed" in a formula?  I'm trying to create a more interesting layout than simple lines...


Link to comment

Ignore everything I wrote below.


CHAR(10) is a line break.


=CONCAT('Plant Record'.'Latin Name', CHAR(10), 'Plant Record'.'Comment 1')


Possible, and not even hard but a little convoluted.


In a worksheet spreadsheet cell, edit the row height so you can see at least two rows of text.


In the cell type any character you choose.

Hold down the Option key and press Return

Type another character.


You should now have a cell with a "line break" character in it.


Move the cursor to before the character on the second row.

Hold down the shift key and press the back arrow.  The "line break" should be highlighted.


Paste into your formula between two single quotes. The formula will "line break" at that point. Click the disclosure triangle at the right end of the formula bar so you can see both lines.



  • Love 1
Link to comment

Thanks for your help already! 🙂

To sum up, here's the objective:
To have several fields in a single table cell, in an attempt to create a more interesting layout than a simple table.  The test file is appended.


in the meantime I had found the CHAR(10) trick: https://developer.vectorworks.net/index.php/VS:Chr


What almost works:
The CONCAT formula refers to cells in the same table.

=CONCAT(D3; (CHAR(13)); 'Flowering: '; E3; (CHAR(13)); (CHAR(13)); 'In a few words: '; F3)

But it seems that the number of characters is limited, as the end of the text in F3 is missing.  I couldn't find any information on character limitation in the reference manual.  Another problem is that I have to refer to columns in the same table, which is inconvenient for printing.  I've tried referencing the data in the other table but as it's a dynamic list this doesn't work as it returns the value of the leading row only, not the list.

I've tried @Pat Stanford's  formula, but it doesn't work (I'm running Windows 10, so I've replaced the commas (,) with semicolons (;) ).



Any idea?



Test tableau Copie.vwx

Edited by Nico_be
Link to comment

It is a limitation of the CONCAT function. It appears to still be using strings that has a length limit of 255 characters. 


Database Subrow cells seem to handle up to 336 characters.


I don't this you are going to find a work around for this to format this they way you want.


You might want to look at Graphical Legends instead as they might be able to do this.

  • Like 1
Link to comment

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Create New...