Skip to Content
It is currently December 11th, 2019, 7:41 pm

All times are UTC - 6 hours [ DST ]




Post new topic Reply to topic  [ 9 posts ] 
Author Message
 Post subject: 2 sams
PostPosted: June 20th, 2014, 3:02 pm 
Offline
Junior User
Junior User

Joined: May 31st, 2014, 8:18 am
Posts: 61
Can I run 2 Broadcasters at the same time with the same data base (MySQL) with no problems?


Top
 Profile  
Reply with quote  
 Post subject: Re: 2 sams
PostPosted: June 20th, 2014, 6:14 pm 
Offline
SVS Member
SVS Member

Joined: December 6th, 2004, 9:00 am
Posts: 7888
Location: Aachen (Germany)
Are you talking about the same database SERVER or really the same DATABASE / database SCHEMA?
The first is fine, the second is a bad idea. SAM is not transaction-safe, so you could easily run into conflicts (both writing and reading).
If you really need to have the same source for two SAM instances, you're better off if you set up replication to another database server.

_________________
Benedikt Bauer - SVS (Spacial Volunteer Support)

We're offering custom PAL / PHP code and general SAM assistance at palscripts.com

My Project:
Send "Now Playing" from SAM to Twitter and/or Facebook | Sourcecode


Top
 Profile  
Reply with quote  
 Post subject: Re: 2 sams
PostPosted: July 9th, 2014, 8:09 pm 
Offline
Alumni
Alumni

Joined: October 14th, 2006, 9:38 am
Posts: 5986
Location: Deep in the heart of the PRNJ
I have run two different stations using different schemas in the same database (SAMAM, SAMFM). The stations even shared songs from a single library.

fwiw

_________________
- Stan Olochwoszcz
A proud licensed SAM user since 2002

Raritan Bay Radio


Top
 Profile  
Reply with quote  
 Post subject: Re: 2 sams
PostPosted: July 22nd, 2014, 12:14 am 
Offline
Senior User
Senior User

Joined: August 31st, 2010, 2:10 pm
Posts: 77
@Elevatorboy: I am curious how you did that. Because the schema is mainly a rights thing. In that case both stations end up with the same events, history etc.

Or am I thinking wrong.

Thanks in advance for your info.

_________________
Currently using SB 2014.6


Top
 Profile  
Reply with quote  
 Post subject: Re: 2 sams
PostPosted: July 22nd, 2014, 8:40 am 
Offline
SVS Member
SVS Member

Joined: December 6th, 2004, 9:00 am
Posts: 7888
Location: Aachen (Germany)
something wrote:
Or am I thinking wrong.

You are. Schema and Database are usually used as synonyms. The Database word is a bit arbitrary as it can be used to mean a single database server or the database engine as well, depending on context.
The hierarchy is like this: Column < Row < Table < Schema

_________________
Benedikt Bauer - SVS (Spacial Volunteer Support)

We're offering custom PAL / PHP code and general SAM assistance at palscripts.com

My Project:
Send "Now Playing" from SAM to Twitter and/or Facebook | Sourcecode


Top
 Profile  
Reply with quote  
 Post subject: Re: 2 sams
PostPosted: July 22nd, 2014, 11:43 am 
Offline
Senior User
Senior User

Joined: August 31st, 2010, 2:10 pm
Posts: 77
Not sure I can follow you:

Elevatorboy said "I have run two different stations using different schemas in the same database (SAMAM, SAMFM). "

So he is using 2 different databases in the same database?

Or is it in MySQL more a naming like SAMAM.songlist and SAMFM.songlist etc? Can work SAM work with these namings?

_________________
Currently using SB 2014.6


Top
 Profile  
Reply with quote  
 Post subject: Re: 2 sams
PostPosted: July 22nd, 2014, 1:11 pm 
Offline
Alumni
Alumni

Joined: February 10th, 2003, 7:07 pm
Posts: 902
Location: Dallas, Texas
Just to help clarify things, the default database/schema is 'samdb'. The database server software is 'MySQL'. So you can use the same database server software to run multiple instances of SAM but it is not recommended that you run multiple instances pointing to the same database/schema under that same server software.

_________________
-Jay | Spacial.com


Top
 Profile  
Reply with quote  
 Post subject: Re: 2 sams
PostPosted: July 22nd, 2014, 3:02 pm 
Offline
SVS Member
SVS Member

Joined: December 6th, 2004, 9:00 am
Posts: 7888
Location: Aachen (Germany)
something wrote:
So he is using 2 different databases in the same database?

ONE computer, ONE MySQL software server running, TWO SAMs (or two instances) pointing to 2 different database-names (i.e. SAMAM and SAMFM instead of the default SAMDB)

something wrote:
Or is it in MySQL more a naming like SAMAM.songlist and SAMFM.songlist etc? Can work SAM work with these namings?

Prefixing your table names is impossible with SAM. The tables must be named exactly the way SAM creates them by default.
Also the way you seperate the prefix from the rest is incompatible with MySQL (and most other database systems) as the dot character is already used as the separator symbol. (To seperate database/schema from table or to seperate table from column/field. I.e.: SELECT s.title, q.songID FROM songlist s, queuelist q or SELECT * FROM samdb.songlist)

_________________
Benedikt Bauer - SVS (Spacial Volunteer Support)

We're offering custom PAL / PHP code and general SAM assistance at palscripts.com

My Project:
Send "Now Playing" from SAM to Twitter and/or Facebook | Sourcecode


Top
 Profile  
Reply with quote  
 Post subject: Re: 2 sams
PostPosted: July 23rd, 2014, 12:03 am 
Offline
Senior User
Senior User

Joined: August 31st, 2010, 2:10 pm
Posts: 77
Mastacheata wrote:
something wrote:
So he is using 2 different databases in the same database?

ONE computer, ONE MySQL software server running, TWO SAMs (or two instances) pointing to 2 different database-names (i.e. SAMAM and SAMFM instead of the default SAMDB)

something wrote:
Or is it in MySQL more a naming like SAMAM.songlist and SAMFM.songlist etc? Can work SAM work with these namings?

Prefixing your table names is impossible with SAM. The tables must be named exactly the way SAM creates them by default.
Also the way you seperate the prefix from the rest is incompatible with MySQL (and most other database systems) as the dot character is already used as the separator symbol. (To seperate database/schema from table or to seperate table from column/field. I.e.: SELECT s.title, q.songID FROM songlist s, queuelist q or SELECT * FROM samdb.songlist)


Thanks for the information Mastacheata (& Jay). Still learning in (My)SQL :)

_________________
Currently using SB 2014.6


Top
 Profile  
Reply with quote  
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 9 posts ] 

All times are UTC - 6 hours [ DST ]


Who is online

Users browsing this forum: No registered users and 16 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB® Forum Software © phpBB Group