Learning SQL

Hello!

I'm new to this forum as my position changed within the last year from Box Office Manager to a more IT related field of Tessitura Database Manager.  I've been learning a great deal through Tessitura training courses offered and the assistance of Tessitura support, however I hit a road block when it comes to anything requiring SQL knowledge which pops up very frequently.  Since I didn't come from an IT background, I'm lost when it comes to this and it gets tough when I keep having to go to Consulting and present a charge to Administration to get a task completed.  Do any of you have advice on how to gain basic SQL knowledge to do tasks in Tessitura.  And if there are any of you who were in this same position, how did you go about learning and moving forward?

Thank you so much,

Melanie

  • Congrats on your new position! I was in the same boat just a couple years ago, and my favorite exercise was recreating some existing lists or reports using SQL. Not only did it give me experience building queries and joins, but it was a great way to gain some more familiarity with the impresario tables and views.

  • Melanie,

    There are a number of great online tools; W3Schools is good as a reference.  The single most basic way to learn your SELECT statements as well as how the tables in Tessitura work is to take all of your lists, and look at the query it forms.  Looking at the "Show Query" is where I started.

    John

  • I took a 3 day introductory SQL course through a company called Webucator. It was really helpful.

  • Hi Melanie,

    Welcome to the wonderful world of SQL!  About 17 years ago, I sort of fell into an IT career as well.  I was fortunate that the CIO sent me to a weeklong sql class, and that I was surrounded by people in the department who were patient with me.  If you are having to learn on your own, I would highly recommend the Stairway series at sqlservercentral.com.  Also, the Women in Tech group is a good place to join in for a monthly Lean Coffee session and any topic is welcome.  Lastly, feel free to reach out to this forum, or you can email me directly (sheleheda@trustarts.org) should you need help with a specific query.  I've probably run through most of them.

    Best,

    Nancy

  • Hi Melanie, welcome!  

    I have totally been in your shoes. I started out as a box office manager, and quickly made my way towards database work. I agree with others that w3schools is great.  I'd personally recommend a class though.  I found an inexpensive one that I could take on Udemy (search for T-SQL there), and that helped so much! That way you can focus on the things you actually want and envision yourself using while having a teacher's support, but without having to put a ton of money into it. I also wouldn't hesitate to search the forums for what you want. A lot of help with code has been provided here, so your solution might already exist. 

    Is there anything in particular that you want to be able to do with SQL and Tessitura?

    I'm always happy to help as well! Don't hesitate to reach out. I'm definitely no SQL veteran, but I can hold my own, and having started my learning journey in the past 3 years, some problems you run into might be fresh in my brain, haha. 

  • One thing about this that confused me was how Tessitura creates aliases.  When you see those a., b., c., etc before information, just know that those are the aliases for the tables.  They aren't really intuitive, especially when first learning. :)  

  • Hi Melanie,

    There are plenty of us that have been in your position and there are plenty that are there at the moment. The tessitura community is exceptional when it comes to help so don't be a stranger. Formal SQL training is a good start and don't worry if you feel that imposter syndrome kick in. You'll find yourself on the internet searching queries and ending up in stackoverflow etc for a lot of answers. 

    Things I've found invaluable (especially when getting started)

    and this little Query for names of all tables which contain column with name: 

    SELECT          c.name  AS 'ColumnName' 
                            t.name AS 'TableName' 
    FROM             sys.columns c 
    JOIN                sys.tables  t   ON c.object_id = t.object_id 
    WHERE           c.name LIKE '%perf_no%' 
    ORDER BY     TableName ,ColumnName; 

    Keep a record of all your code with notes, whether it be a word doc or bitbucket/boostnote/whatever

    We're here to help.

    Heath

  • Melanie,

    This seems to be a common path into the dark arts of SQL - my own included. As others have mentioned, W3Schools and stack Overflow are great resources but the VERY BEST resource is the Tessitura community. The folks here are unflinchingly generous with their time and expertise, probably because we've all been in the same position. And we know the Tessi database pretty well by now - there probably isn't a scenario one of us hasn't encountered!

    As someone who's made a couple of disastrous mistakes, please, please, please hone your skills with SELECT statements first and ALWAYS remember to try anything that deletes or updates in your TEST environment first. 

  • Something I wish I was told at the start … when you are going to INSERT/UPDATE/DELETE into the data base learn to use a BEGIN TRANSACTION / ROLLBACK TRANSACTION statement. 

    If ever I've thought about doing something daft (I won't give examples) and I figure I should probably run it by Tessitura Support first, do it.  

  • Former Member
    Former Member $organization

    Hi and welcome to the club.  SQL can be daunting at first but with a little bit of practice it becomes much clearer to understand I promise. As already suggested I found recreating lists and just scripting out stored procedures to see if I could make sense of what they were doing and how things linked together a good place to start. I found www.udeny.com a really useful resource. They've got some good free courses that cover the basics. I definitely agree with Heath and Martin, if you aren't using any form of source control keep a note of your code (new and original) and always work in a test environment first.  One thing I will say if having that front end knowledge and experience of how Tessitura works is a huge bonus.  Good luck. 

  • Fully agreed.  When you do get to the point of actually making changes to the database, make sure to use Transactions/all of the safety tools at your disposal to avoid doing something like... well, I have my own examples that probably compare well with Heath's.  Error handling is exceptionally useful, but I did not embrace it early on.  I had liked to think "but I write GOOD code that does not cause errors, so that is not needed"... but that was me being dumb.  Even the best code can run and do exactly what it is supposed to do and end up causing an error because the source information was something completely unanticipated and/or at fault itself.

    And indeed be certain to test it in your TEST database first (I still do not do that enough).

  • Welcome to the club of accidental IT! The resources everyone else has shared are the same ones I would recommend. One thing I'll add is that the slack channel for developers is really great too - you can request access here: https://www.tessituranetwork.com/en/Support/Start/Developers/Access I'd say at least half the conversations are over my personal skill level, but it's really helped me figure out what to learn next.

  • Wow!  Thank you all so much.  I didn't expect to get so many responses.  It's so reassuring that I'm not the only one and there are so many people willing to help!  I'll be taking a look at the resources you all sent and reaching out with questions, I'm sure!

  • Welcome to the club, etc. :-) BOM to DBA seems exceedingly common, myself included. I've always had a strong distaste for w3schools which I won't go into explaining here, but here are the resources I'd recommend in lieu of that that I don't see represented here yet:

    * Microsoft SQL Server docs, T-SQL Reference: This is always going to be the most reliable resource for the specific syntax used in SQL Server. SQL is really a family of related dialects, which have subtle differences depending on what kind of database server is being used. Tessitura is built on top of Microsoft SQL Server, which uses a dialect of SQL called "Transact-SQL", often abbreviated "t-sql". A good habit to get into with your google search queries would be to always include "t-sql" or "tsql" as a search term, so you will be directed to resources that are specific to the SQL Server dialect. The T-SQL Reference linked here is a technical resource which may pose a bit of a learning curve, but once you've learned how to navigate it and are more familiar with the terminology, it really is invaluable. (Also want to +1 bump Nancy's suggestion of the Stairway to T-SQL DML, Beyond the Basics, and Advanced T-SQL articles from sqlservercentral.com -- another great resource specific to transact-sql.)

    * LinkedIn Learning: For other reasons I won't go into explaining here, I also have a strong distaste for LinkedIn (boy am I picky!) but luckily, you can access all of the content on LinkedIn Learning for free, without even a LinkedIn account, through many public libraries with your library card! This originates with Lynda.com (which had access agreements with many public libraries) having been acquired by LinkedIn and having recently been integrated. So, if you're looking for high-quality long-form video courses but aren't able or interested in paying for Pluralsight or Udemy, LIL has an entire category of Transact-SQL courses available. Getting access just requires finding a library that you are eligible to have a library card with that also has access to the LIL database; for example, anyone in the state of New York can receive a virtual card via the New York Public Library web site, and this can be used to log in to LIL. Other states and locales may have luck through local colleges and universities if local public libraries do not have access.