Welcome to the LimeSurvey Community Forum

Ask the community, share ideas, and connect with other LimeSurvey users!

.lsg format

  • jparis
  • jparis's Avatar Topic Author
  • Offline
  • New Member
  • New Member
More
4 days 14 hours ago #270194 by jparis
.lsg format was created by jparis
Please help us help you and fill where relevant:
LimeSurvey version: 6.9.0+241218
Own server or LimeSurvey Cloud: Own
Survey theme/template: Extended Skelvanilla
==================
Hi again,

I'm trying to understand how the .lsg files exported from LS are made and I have one question about them.
I found everything right, it's a XML file so it's easy to understand but I found some duplicated info inside the group_l10ns tag, maybe to be compatible with some changes in new LS versions? If that's the reason, do LS need it? Could someone show me the meaning/use of the main tags or point me to the right document?

I would like to do an external app that could generate a .lsg file, we have a lot of surveys, all of them with the same format, same number of questions, same number of answers, etc. and they are on CSV files and would be nice to automate the process of getting them in LS and I thought that it could be fine to do it via .lsg files to be able to insert them inside a main survey.

Thanks in advance

Please Log in to join the conversation.

  • Joffm
  • Joffm's Avatar
  • Offline
  • LimeSurvey Community Team
  • LimeSurvey Community Team
More
4 days 11 hours ago #270195 by Joffm
Replied by Joffm on topic .lsg format
Hi,

I found some duplicated info inside the group_l10ns

Which info do you think to be duplicated? Please, show.

And did you compare with the values in the database?

Joffm

Volunteers are not paid.
Not because they are worthless, but because they are priceless

Please Log in to join the conversation.

More
4 days 6 hours ago #270196 by parisjp
Replied by parisjp on topic .lsg format
Hi,

Just reread the XML and:

 

As you can see the gid, group_order, randimization_group and grelevance labels are duplicated inside groups/fields and inside group_l10ns/fields. And, of course, the row label inside each one contains said labels with the same info inside groups and inside group_l10ns.

it's not this way if you look inside questions and question_l10ns:

 

It seems that questios label contains all "technical" info about the questions and question_l10ns contains the question text, help text, language... No duplicates but qid that works as an key between both, I suppose.

Same goes for answers label:

 

Answers label contains more "tech" info and answer_l10ns contains answers text and so.

So I wonder why groups behaves different... It's my mind, I need to kanow the details for pace of mind... To implement what I need it's only matter of searching for the labels and replace/fill what I need, but I like to know how/why things work so my interest about it. Maybe "l10ns" has some meaning?

Thanks
 

Please Log in to join the conversation.

More
4 days 6 hours ago #270197 by parisjp
Replied by parisjp on topic .lsg format
Hi Joffm,

No, I didn't compare. Is just a matter of knowing exactly how it's supposed to work as XML syntax is easy to follow and understad.

Here you have how the group and group_l10ns labels are populated:

 

As you can see all the labels inside groups/fields are duplicated inside group_l10ns/fields. I wonder why?

It's not the same if you look at questions:

 

No duplicates, only qid that serves as a key to sync databases I suppose.

Same for answers:

 

No duplicates, in this case the key is aid for the same matter.

So, as said, I wonder why groups and group_l10ns are not so tidy as questions, answers and their 'l10ns' siblings are. I'm not questioning anything, I suppose there must be a reason for that, but I would like to understand that.

Actually I don't need to know it, for the shake of what I'm trying to do (import CSV data inside the .lsg file) it's only question to parse the XML, and replace/fill the data I need but, I like to know how things work...

Thanks

Please Log in to join the conversation.

More
4 days 6 hours ago #270198 by parisjp
Replied by parisjp on topic .lsg format
Hi Joffm,

No, I didn't compare. Is just a matter of knowing exactly how it's supposed to work as XML syntax is easy to follow and understad.

Here you have how the group and group_l10ns labels are populated:

 

As you can see all the labels inside groups/fields are duplicated inside group_l10ns/fields. I wonder why?

It's not the same if you look at questions:

 

No duplicates, only qid that serves as a key to sync databases I suppose.

Same for answers:

 

No duplicates, in this case the key is aid for the same matter.

So, as said, I wonder why groups and group_l10ns are not so tidy as questions, answers and their 'l10ns' siblings are. I'm not questioning anything, I suppose there must be a reason for that, but I would like to understand that.

Actually I don't need to know it, for the shake of what I'm trying to do (import CSV data inside the .lsg file) it's only question to parse the XML, and replace/fill the data I need but, I like to know how things work...

Thanks

Please Log in to join the conversation.

More
4 days 6 hours ago #270199 by parisjp
Replied by parisjp on topic .lsg format
Hi Joffm,

No, I didn't compare. Is just a matter of knowing exactly how it's supposed to work as XML syntax is easy to follow and understad.

Here you have how the group and group_l10ns labels are populated:

 

As you can see all the labels inside groups/fields are duplicated inside group_l10ns/fields. I wonder why?

It's not the same if you look at questions:

 

No duplicates, only qid that serves as a key to sync databases I suppose.

Same for answers:

 

No duplicates, in this case the key is aid for the same matter.

So, as said, I wonder why groups and group_l10ns are not so tidy as questions, answers and their 'l10ns' siblings are. I'm not questioning anything, I suppose there must be a reason for that, but I would like to understand that.

Actually I don't need to know it, for the shake of what I'm trying to do (import CSV data inside the .lsg file) it's only question to parse the XML, and replace/fill the data I need but, I like to know how things work...

Thanks

Please Log in to join the conversation.

More
4 days 6 hours ago #270200 by parisjp
Replied by parisjp on topic .lsg format
Hi Joffm,

No, I didn't compare. Is just a matter of knowing exactly how it's supposed to work as XML syntax is easy to follow and understad.

Please check how group and group_l10ns labels are populated, you will see all the labels inside groups/fields are duplicated inside group_l10ns/fields. I wonder why?

It's not the same if you look at questions. No duplicates, only qid that serves as a key to sync databases I suppose.

Same for answers. No duplicates, in this case the key is aid for the same matter.

So, as said, I wonder why groups and group_l10ns are not so tidy as questions, answers and their 'l10ns' siblings are. I'm not questioning anything, I suppose there must be a reason for that, but I would like to understand that.

Actually I don't need to know it, for the shake of what I'm trying to do (import CSV data inside the .lsg file) it's only question to parse the XML, and replace/fill the data I need but, I like to know how things work...

Thanks

Please Log in to join the conversation.

More
4 days 6 hours ago #270201 by parisjp
Replied by parisjp on topic .lsg format
Hi Joffm,

No, I didn't compare. Is just a matter of knowing exactly how it's supposed to work as XML syntax is easy to follow and understad.

I don't know why I can't attach files today... So text only...

If you look in a lsg file how the group and group_l10ns labels are populated, you'll see that all the labels inside groups/fields are duplicated inside group_l10ns/fields. I wonder why?

It's not the same if you look at questions. No duplicates, only qid that serves as a key to sync databases I suppose.

Same for answers. No duplicates, in this case the key is aid for the same matter.

So, as said, I wonder why groups and group_l10ns are not so tidy as questions, answers and their 'l10ns' siblings are. I'm not questioning anything, I suppose there must be a reason for that, but I would like to understand that.

Actually I don't need to know it, for the shake of what I'm trying to do (import CSV data inside the .lsg file) it's only question to parse the XML, and replace/fill the data I need but, I like to know how things work...

Thanks

Please Log in to join the conversation.

  • DenisChenu
  • DenisChenu's Avatar
  • Offline
  • LimeSurvey Community Team & Official Partner
  • LimeSurvey Community Team & Official Partner
More
3 days 19 hours ago #270204 by DenisChenu
Replied by DenisChenu on topic .lsg format
(Seems there is an issue with your account : each post needs to be approved manually)

Else : right, seems strange about group_l10ns : i don't see any reason for this.

Maybe report the issue ?

Assistance on LimeSurvey forum and LimeSurvey core development are on my free time.
I'm not a LimeSurvey GmbH member. - Professional support - Plugins, theme and development .
I don't answer to private message.

Please Log in to join the conversation.

  • jparis
  • jparis's Avatar Topic Author
  • Offline
  • New Member
  • New Member
More
3 days 17 hours ago #270205 by jparis
Replied by jparis on topic .lsg format
Hi Denis,

Yes, yesterday I posted the reply and didn't appear so I did several tries with different "setups" and was not able to see the post so I leave it to try today and my surprise is that all of them are posted...

It's strange to me that duplicity, let's wait to see if Joffm or anybody has a clue about this matter and then could raise the issue

Please Log in to join the conversation.

  • Joffm
  • Joffm's Avatar
  • Offline
  • LimeSurvey Community Team
  • LimeSurvey Community Team
More
3 days 16 hours ago #270206 by Joffm
Replied by Joffm on topic .lsg format

Could someone show me the meaning/use of the main tags or point me to the right document?

Therefore I ask whether you compared.
The structure of the database gives you all informations about the relation between the lss / lsg / lsq exports and the data.

And as @Denis: Report the issue, but first update to the actual version. Could have been a temporaray bug that is fixed already.
I could not reproduce neither in 6.4.12. nor in 6.12.4. nor in SaaS version 6.13.0.


Joffm

BTW:
Did you import this lsg export with the "double" part?
Did you import this lsg export without the "double" part?
So probably you can simply ignore it (really seems to be something in your installation), and create your lsg file as usual.

 

Volunteers are not paid.
Not because they are worthless, but because they are priceless

Please Log in to join the conversation.

Moderators: holchtpartner

Lime-years ahead

Online-surveys for every purse and purpose