• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Cannot seem to create the database on BaseX 10.5 properly using an XML file, any help?

 
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Trying to create a database using the "Cities_XML_Data".xml file in BaseX 10.5. But when I create the database and go to Table view, all the attractions for each of the cities are under a single column and separated by semi-colons (;), hence I have not been able to query the database properly. Any help in this regard?

Have attached a screenshot for what the problem is, can also share the XML file if anyone wants to assist.

Much appreciated!
XML-file.PNG
[Thumbnail for XML-file.PNG]
 
Marshal
Posts: 28261
95
Eclipse IDE Firefox Browser MySQL Database
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Are the semicolons in the XML file, or are they inserted into that column in that database table by some process which you ran?

It seems to me that there should be two tables, one for city data and the other for attraction data. Was that what you expected, or was the conversion process supposed to produce only one?
 
Khondokar Abu Saleheen
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi Paul,

Thank you for your time.

So as far I can see in the XML file, there is no such semicolons. When I go to create a database using the XML file and using BaseX 10.5 as the platformfor query purposes, the database is being created like this.

Any idea what I can do in this regard?
 
Khondokar Abu Saleheen
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Also, to answer another one of your query, yes there was only supposed to be a single table, where I can find results using xPath and xQuery instructions,
 
Paul Clapham
Marshal
Posts: 28261
95
Eclipse IDE Firefox Browser MySQL Database
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
If you want only one table then you would naturally have all of the attractions for a city packed into a single column of the city table. So how would you like to separate them if not with a semicolon?

And you keep saying things like "the database is being created" as if this was happening by magic. I have no doubt that there is some software involved in this creation; you should strongly consider looking into that.
 
Paul Clapham
Marshal
Posts: 28261
95
Eclipse IDE Firefox Browser MySQL Database
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Khondokar Abu Saleheen wrote:Also, to answer another one of your query, yes there was only supposed to be a single table, where I can find results using xPath and xQuery instructions,



But those are XML technologies. Do you really plan to apply them to a database table, instead of the original XML document?
reply
    Bookmark Topic Watch Topic
  • New Topic