anchor.diff:  				if(last_editor)
   					output += "<br><span class='memoedit'>Last edit by [last_editor] <A href='?_src_=holder;mentormemoeditlist=[ckey]'>(Click here to see edit log)</A></span>"
   				output += "<br>[memotext]</span><br>"
  +			qdel(query_memoshow)
   			if(!output)
   				to_chat(src, "No memos found in database.")
   				return
  
positive.code: 			var/datum/DBQuery/query_memofind = SSdbcore.NewQuery("SELECT memotext FROM [format_table_name("mentor_memo")] WHERE ckey = '[target_sql_ckey]'")
  			if(!query_memofind.Execute())
  				var/err = query_memofind.ErrorMsg()
  				log_game("SQL ERROR obtaining memotext from memo table. Error : \[[err]\]\n")
  				return
  			if(query_memofind.NextRow())
  				var/old_memo = query_memofind.item[1]
  				var/new_memo = input("Input new memo", "New Memo", "[old_memo]", null) as message
  				if(!new_memo)
  					return
  
negative.code: 				else
  					log_admin("[key_name(src)] has edited [target_sql_ckey]'s mentor memo from [old_memo] to [new_memo]")
  					message_admins("[key_name_admin(src)] has edited [target_sql_ckey]'s mentor memo from<br>[old_memo]<br>to<br>[new_memo]")
  				qdel(update_query)
  			else
  				qdel(query_memofind)
  		if("Show")
  			var/datum/DBQuery/query_memoshow = SSdbcore.NewQuery("SELECT ckey, memotext, timestamp, last_editor FROM [format_table_name("mentor_memo")]")
  			if(!query_memoshow.Execute())
  				var/err = query_memoshow.ErrorMsg()
  				qdel(query_memoshow)
  				log_game("SQL ERROR obtaining ckey, memotext, timestamp, last_editor from memo table. Error : \[[err]\]\n")
  				return
  			var/output = null
  