Hi guys,

Thanks a lot sparrow for the steps and insights.
I'll do these asap.

Yes I had found the xml files of Persona and converted them to csv but I'm not familiar with it yet so I couldn't use it.
attachments-us1-cloud-deskpro-com.s3.amazonaws.com/files/962/294/293258JMXAWQTNQRXRMYY0-Persona-Extra-Samples.zip
convertcsv.com/xml-to-csv.htm

Get back asap with next progress!

Hi all,

Thanks Derek for that example.

I came that far with my project in attachment:
the project (with the script of interest)
paste.c-net.org/StanleyTower
the db files
paste.c-net.org/ConnellYummy

I'm not sure about how to get  forward with the script as
my database design skills are rudimentary and I doubt the schema is correct but it seems
I can't make more connections as per given by the Persona model.

Could anyone point me toward next recommended steps I should be taking
in order to display the database characters names in the treeview?

I should be able to proceed from there with the tags filtering, likely by using a a 2dn form
as with the Persona model.

Thanks again!

Thanks sparrow and Derek for the solution hints.

I found the SQL Query reference in the guide under the button menu
(which function requires a tablegrid object for displaying the output rather than my previously used memo3):
myvisualdatabase.com/help_en/SQLquery.html
(I had been looking for the SQLQuery documentation using the SQLQuery keyword, which returned nothing, but SQL Query did).

Then got the SQL syntax corrected from this great resource and pointer post:
sqlitetutorial.net/sqlite-subquery/
myvisualdatabase.com/forum/viewtopic.php?pid=45037#p45037

SELECT  mname
FROM musicians
WHERE musicians.id = (
   SELECT id_musicians
   FROM Alb_info
   WHERE Year = '1978'
);  

It now outputs as expected:
ibb.co/D1GTHsr
ibb.co/kQkHRKV
ibb.co/mtGrFzN
ibb.co/p2w9NSf

The latest script:
https://paste.c-net.org/RapportHendrix

Sparrow, you mentioned the use of SQLExecute function.
Is there some way to output the SQL Query result in a Treeview when using a script with the SQLExecute function?
Avoiding the use of a button? I'd like to display the output straight from clicking the "MUSICIANS" menu if possible.
If so, do you know of some sample or example I should be referencing?

Thanks again for your remarks.
Regards,
Frank

Many thanks to everyone for your great insights and contributed scripts!

I've looked and done some tests with Derek's treeview music m.zip script version from sparrow.
Here is my latest modification:
paste.c-net.org/GatherLimited

In summary, I added a GroupBox3 to the form and tried modifying the script
by adding a SQL command to the top level tree node { to execute when clicking the "MUSICIANS" treeview Menu }.

The idea would be to ouptut the Musicians names matching the SQL command inside the
Memo3 field in the GroupBox3, upon clicking the MUSICIANS treeview entry.

I tested the following query which returns a " not enough actual parameters at 38.18" error:
ibb.co/JRmPpZK

         SQLQuery('SELECT mname FROM musicians WHERE musicians.id in (select Alb_info.id_musicians from Alb_info where Alb_info.Year = "1978")');
         { SQLQuery("SELECT musicians.mname FROM musicians, Alb_info WHERE Alb_info.id = '1978' "); }
         { SQLQuery('SELECT id_musicians FROM Alb_info where Alb_info.Year = "1978" ');  }
         { SQLQuery('SELECT * FROM musicians'); }
         Form1.Memo3.Text := Results.FieldByName('mname').AsString;


I also tested the other commented out SQL commands above which return the same error.

I could not find a solution or helpful suggestion online to this issue despite finding some good resources
stackoverflow.com/questions/10829812/sql-query-where-value-of-another-table
codeproject.com/Articles/33052/Visual-Representation-of-SQL-Joins
stackoverflow.com/questions/5446778/select-from-one-table-matching-criteria-in-another

Is there some specific SQL syntax to MVD I'm missing? If so could any one point me toward the relevant documentation on this topic?
Else any suggestion about likely SQL syntax or logic error pointer would be very appreciated.

The SQL command above should return the Musician name according to the
search criteria matching the id_musicians value from both tables,
but based on the corresponding Year field/colum value matching the 1978 value.

RUST NEVER SLEEP should be returned for that example.
ibb.co/XLfCvFH

The idea would be next to expand this query to match any "tag" / string value from a given column/field
to replicate the original project.
And ultimately try to do the same with a second treeview instead of a memo3 field to get the final result
of selectable record from the created groups, if possible.

Many thanks again for your next suggestions!

Regards,
Frank

Hi Derek,
Thanks a lot for the good suggestions and combining forms remarks.
About the idea you suggested of taking a look at other similar treeview projects, do you know of such projects I should be looking at to get up and running?
I just found about this online guide:
myvisualdatabase.com/help_en/TreeView1.html
It is quite detailed. I'll study it and be back asap with the data.
Regards,
Frank

Hi Derek,
Many thanks for your reply and insights.
I am slowly but surly rebuilding a similar dataset from the app for later testing.

Couple questions about MVD if I may. I found the user guide at:
myvisualdatabase.com/download/Book_My_Visual_Database.pdf

Is it the latest available release of the manual? I can't find any reference to the treeview in the pdf.
Is there some other resource you could kindly point to for this purpose?

That's interesting you pointed the nodes drag and drop feature as I wondered as well why it was used by the app.
For now I shouldn't really need that feature, it would suffice having a way to filter the records into groups using tags, but if possible more as with the form format of the app rather than a grid, mainly because it would be more convenient for data entry purposes.

Also I see there is a mention of the need of separate forms with MVD for data entry and data search functionalities. Would it be is possible to combine the two functionalities into a single form as with the app?

Many thanks again for you advice and remarks.

Regards,
Frank

tcoton wrote:

Youtube reference not working

Hello,
This forum doesn't let me post images.

Please test this Youtube ID:
/watch?v=o6wqnpdtFQg

It goes after the youtube.com
Thank you.

Hello,

Can this be done with MVD?

Add a treeview to create and select entries,
then auto-display previously filled form fields when selecting treeview entries.

Adding new entries.

Create groups.

Filter groups from the form data.

Here is a 3 minutes Youtube ID of the reference video.
o6wqnpdtFQg

0:10 Clicking treeview entries / auto-display in form
0:31 Creating new entries / filling the form
1:02 Creating Groups
1:19 Filtering groups using form data
1:40 default / pre-made data in database

Thank you for your insights.