tben2505 Posted May 18, 2011 Posted May 18, 2011 Hello folks, I was just wondering (and I have a suspicion this isn't possible) whether you can somehow batch create Aspects in SIMS. It would be a lot easier to create the 100 or so aspects using excel and import them, perhaps as a CTF? I'm pretty sure Yellis/MidYIS' CTF files import aspects - so I wonder how to do it? Cheers Tom
LosOjos Posted May 18, 2011 Posted May 18, 2011 (edited) Hi, and welcome to EduGeek @Dancer posted a tool to do this a while ago, it's saved me many hundreds of hours already I'm sure! There is a sheet within the workbook called "Notes", if you read them you should be able to figure out how it all works FRA_Aspect.zip Edited May 18, 2011 by LosOjos credit where credit's due
tben2505 Posted May 18, 2011 Author Posted May 18, 2011 Wow - amazing - this will save me LOADS of time! Thanks to you and it's writer!! T
LosOjos Posted May 18, 2011 Posted May 18, 2011 Just a word of warning - be very careful about choosing ID's! If you choose an ID that's already in use, you could end up causing some issues... I tend to use "DDMMYYYY_[incrementing number]" each time I do an upload, that way it's going to be a unique ID and you have some sort of auditing possible with the upload date attached
tben2505 Posted May 18, 2011 Author Posted May 18, 2011 Good call. At the moment I'm just testing it to ensure it updates the relevant text file(s) but it doesn't seem to be doing anything... is there a particular version of Excel where this works best? Didn't work with 2010 or 2003...
LosOjos Posted May 18, 2011 Posted May 18, 2011 Good call. At the moment I'm just testing it to ensure it updates the relevant text file(s) but it doesn't seem to be doing anything... is there a particular version of Excel where this works best? Didn't work with 2010 or 2003... Have you read through all of the notes? Also, have you made sure you have enabled macros in Excel? There are two text files that have to be in the same folder as the spreadsheet (it's an XLS so should work fine with any version of Excel). In the "OrigAspect.txt" file, you have to have copied and pasted the XML code for an existing aspect you have exported from your SIMS system. What this spreadsheet actually does is then replace the relevant parts of that original aspect to create the XML for new aspects you've specified, creating a new XML file in "NewAspects.txt", ready to be uploaded in to SIMS (you'll need to make a copy of the file and change the extension to ".xml" to be able to upload it) Let me know if you're still having problems and I'll see if I can help you out.
tben2505 Posted May 18, 2011 Author Posted May 18, 2011 Aaaah - I did read the notes but I didn't fully understand that it required me to do that - I thought it was already (or should already) hve been there. Will try this now, then! On a side not, is it possible to attach grade sets to these aspects during this process, do you know, or do we have to append them to each aspect in SIMS? Cheers!
tben2505 Posted May 18, 2011 Author Posted May 18, 2011 Ah it'll already be there in the export. I'm catching on, sorry!
LosOjos Posted May 18, 2011 Posted May 18, 2011 Ah it'll already be there in the export. I'm catching on, sorry! Yep, it all depends on the original aspect you're basing your batch creation on, so you do have to be careful that the original is the same type and gradeset as all those you want to create based on it, but it's still much quicker than doing it all manually I think!
tben2505 Posted May 18, 2011 Author Posted May 18, 2011 Unfortunately seems to be an error with my generated file now! I can generate the file OK but it seems the header information is slightly wrong? Can you see?!! Thanks, TomNewAspects.rar
tben2505 Posted May 18, 2011 Author Posted May 18, 2011 (error on import to SIMS) "file contains invalid data. select another file"
vikpaw Posted May 18, 2011 Posted May 18, 2011 I believe that person may have been Dancer - a.k.a. Ralph on SupportNet. At least it was him that did the routine for marksheets. Was just thinking that you can import aspects, especially, as mentioned when sent from some third party. When you do this, doesn't it create it's own ID on import? To maintain integrity a bit more, why not batch create your aspects on a test server. Then export them for reimport to the live server, this way it can handle the IDs or am i talking rubbish?
LosOjos Posted May 18, 2011 Posted May 18, 2011 I believe that person may have been Dancer - a.k.a. Ralph on SupportNet. At least it was him that did the routine for marksheets. Was just thinking that you can import aspects, especially, as mentioned when sent from some third party. When you do this, doesn't it create it's own ID on import? To maintain integrity a bit more, why not batch create your aspects on a test server. Then export them for reimport to the live server, this way it can handle the IDs or am i talking rubbish? I'd never accuse you of talking rubbish Vik lol, but I think you're wrong here. The ID appears to have to be manually created (unless you create an aspect in SIMS, where it automatically creates one). If you provide no ID in the XML, it won't import, and if you were to run a quick report on your SIMS system and look at some of the external ID's for aspects relating to exam results (you may need "Third Party Reporting" privileges on your login to report on that), you'll see just how bizarre and obfuscated they can get in an attempt to remain unique! I have (only once fortunately) forgotten to change my ID's and imported them to SIMS; the result was that although the correct aspect name appeared in SIMS, upon export, it showed the aspect name I'd accidentally uploaded over the top! That was a painful couple of hours to put right...
LosOjos Posted May 18, 2011 Posted May 18, 2011 @tben2005: that XML is in a right mess! Did you copy the entire XML exported from SIMS in to "OrigAspect.txt"? If as I suspect you have, that's your problem; you only need the aspect part of the XML, that's everything between (and including) the "" tags. You'll also want to delete everything after "" at the start of "NewAspect.txt", and you'll need to do that before each time you run it, as Excel will append to this file, not replace it.
tben2505 Posted May 18, 2011 Author Posted May 18, 2011 OK, firstly, could you just see if my OrigAspect.txt file looks OK...? CES Assessment Services318 6078 The Harrodian School114CES Assessment Services318 6078 The Harrodian School3391KS4R_ArKS4R_Ar18/05/201118/05/2011GFFFF
tben2505 Posted May 18, 2011 Author Posted May 18, 2011 Great. And I've attached the excel file that I'll run - could you just see if that looks OK to you too?FRA_Aspect.xls
vikpaw Posted May 18, 2011 Posted May 18, 2011 Ah, so all imports do have a bizarre ID in them somewhere? So what happens if i export mine, and send them to you for import, are they tagged in some way or would you risk a tiny chance it might have the same id as one of yours. That doesn't sound very robust.
LosOjos Posted May 18, 2011 Posted May 18, 2011 (edited) Spotted your problem: you're using the gradeset external ID when specifying the details of your original aspect (in B3 on the spreadsheet), it's the aspect's ID that you need, which in this case would be 3391 (you can see it in the XML as "3391") Correct that, and it should run fine... Edited May 18, 2011 by LosOjos
LosOjos Posted May 18, 2011 Posted May 18, 2011 Ah, so all imports do have a bizarre ID in them somewhere? So what happens if i export mine, and send them to you for import, are they tagged in some way or would you risk a tiny chance it might have the same id as one of yours. That doesn't sound very robust. Truth is I don't know... that certainly appears to be what would happen, but it does seem like a gaping flaw if it's true... perhaps SIMS also checks the supplier ID that is also in the XML and assigns a new ID if it's from an external supplier? This has got me thinking actually, I'm going to do a little playing, we may be able to make this batch aspect system a little more robust if that's the case... Just on the off chance, @PhilNeal if you're reading, do you know the specifics?
tben2505 Posted May 18, 2011 Author Posted May 18, 2011 Spotted your problem: you're using the gradeset external ID when specifying the details of your original aspect (in B3 on the spreadsheet), it's the aspects ID that you need, which in this case would be 3391 (you can see it in the XML as "3391") Correct that, and it should run fine... You sir, are a genius! Thanks!!
LosOjos Posted May 18, 2011 Posted May 18, 2011 You sir, are a genius! Thanks!! No genius, just spent a long time battling to create an easier life myself along with other members here, glad to be of help though
vikpaw Posted May 18, 2011 Posted May 18, 2011 @LosOjos - that's what i think must happen, because it sets supplier ref and other things, so if you keep some extra info in there it should otherwise we'd all be leaving our systems open to massive corruption just by importing some third party aspects. was it @Dancer that created that macro / routine? perhaps he'll have more of an idea...
LosOjos Posted May 18, 2011 Posted May 18, 2011 @LosOjos - that's what i think must happen, because it sets supplier ref and other things, so if you keep some extra info in there it should otherwise we'd all be leaving our systems open to massive corruption just by importing some third party aspects. was it @Dancer that created that macro / routine? perhaps he'll have more of an idea... I believe it was yes, his name certainly rang a bell when you said it and it was the same person who created the one for templates (all uploaded to SupportNet quite some time back)
ajp233 Posted May 18, 2011 Posted May 18, 2011 Back in the day when I worked in Local Authorities we developed an Excel file that allowed schools to enter KS2 raw scores and marks and obtain a set of reports (tabular and graphical). It also automatically identified students who were within 3 marks of the next level (helped the school identify possible remark requests), and finally it generated a SIMS Assessment Manager xml results file for import into their system via a macro. To give you a flavour the following VBA code creates a File System object called XMLFS, creates a text file called ResKS22010.xml in S:\SIMS\Marks and then begins to write text into the file Set XMLFs = CreateObject("Scripting.FileSystemObject") Set XMLFile = XMLFs.CreateTextFile("S:\SIMS\Marks\ResKS22010.XML", True) ' Write opening lines of XML file with results file Tag and Header Line XMLFile.WriteLine "" XMLFile.Write "" XMLFile.Write "Key Stage 2 Assessment Results 2010" XMLFile.WriteLine "" I'v still got a copy of the Excel file and it is perfectly feasible to adapt it to make bulk generation of aspects not reliant on the existence of 2 additional text files in the same directory as the Excel file. Think I might give it a go actually......something to get my teeth into
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now