[ 
https://issues.apache.org/jira/browse/MARMOTTA-430?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13882782#comment-13882782
 ] 

Jeff Zemerick commented on MARMOTTA-430:
----------------------------------------

I spent last night working on this and what I did is add a new String property 
to KiWiConfiguration called tablePrefix. It is initialized as an empty string 
to preserve backward compatibility. Next, I modified the *.sql and *.properties 
files in the resources to include TABLEPREFIX in front of all table and 
sequence names. I then modified the functions that read from those files to 
replace TABLEPREFIX with the value of tablePrefix in KiWiConfiguration, such as 
getStatement() function in KiWiDialect. There are also a few SQL statements in 
the code and I modified them to also include the tablePrefix in front of any 
database object names. I'm using MySQL so those are the only scripts I've 
modified so far.

Wanted to see if this sounds like a good way to approach this before going any 
further.

> Add support for multiple triplestores in the same database
> ----------------------------------------------------------
>
>                 Key: MARMOTTA-430
>                 URL: https://issues.apache.org/jira/browse/MARMOTTA-430
>             Project: Marmotta
>          Issue Type: New Feature
>          Components: KiWi Triple Store
>    Affects Versions: trunk
>            Reporter: Jeff Zemerick
>            Assignee: Sebastian Schaffert
>            Priority: Minor
>              Labels: kiwi, triplestore
>
> I have a use-case where it would be optimal to store multiple, isolated 
> triplestores in the same database. Using different databases is acceptable 
> for  a very small number of users but that approach does not scale well. The 
> suggested idea is to use table prefixes to maintain separation between the 
> individual triplestores. The changes should be backward compatible and not 
> affect existing users of KiWi Triplestore.



--
This message was sent by Atlassian JIRA
(v6.1.5#6160)

Reply via email to