Dependent Dropdown List

859 views
Skip to first unread message

MarkeTeam Inc Creative

unread,
Jul 29, 2015, 12:04:40 PM7/29/15
to XMPie Interest Group
Morning,

I'm fairly new to XMPie so bare with me.

I am trying to create a simple drop-down list like the example on uStore Online Help (Dependent Drop-down List). I have created my Red Wine and White Wine variables as well as my 3 test reds and 3 test whites on my data source.

When I go into uStore/Dial Details, I do not get anything in the Data Source drop-down list (the Wizard radio button is selected).

I have entered my display name, checked "Take values from Data Source" and entered a couple of test Text and Value names in the value list.

This seems incredibly simple to achieve. Could someone direct me to a step by step tutorial or outline that would guide me from inDesign through uStore or another thread/post on this same subject?

Thank you
empty data source dropdown.png

Sylvain

unread,
Jul 29, 2015, 2:34:41 PM7/29/15
to XMPie Interest Group, cr...@marketeaminc.com
I'm not on the same version of uStore but I'm fairly positive the behavior would be the same, even though my version doesn't openly support "dependent dropdowns".
That "data source" drop down gets populated by the data sources you set in "Preset–>Data Sources Setup"
data_sources_ss.png

MarkeTeam Inc Creative

unread,
Jul 29, 2015, 6:03:14 PM7/29/15
to XMPie Interest Group, blaz...@yahoo.com
Thanks Sylvain. But what if I I have a flat file? ie: .csv

couch

unread,
Jul 29, 2015, 6:41:49 PM7/29/15
to XMPie Interest Group, cr...@marketeaminc.com
Dependent drop-downs require sql datasource table in order to query it to populate the dependent dials. It is not possible to use flat file. Create a new SQL table and import the flat file data.

MarkeTeam Inc Creative

unread,
Jul 29, 2015, 7:04:59 PM7/29/15
to XMPie Interest Group, sco...@gmail.com
Thanks Couch. Could you point me to some documentation in reference to the XMPie database on how I would go about this?

Also, I've noticed others attempting to do something similar in using the HTML Generic. Could you point to me to documentation on that as well?

Thanks again

couch

unread,
Jul 29, 2015, 7:26:12 PM7/29/15
to XMPie Interest Group, cr...@marketeaminc.com
SQL is a Microsoft product - there is plenty of websites out there with help on this. 

Simon Knott

unread,
Jul 30, 2015, 4:09:51 AM7/30/15
to XMPie Interest Group, sco...@gmail.com, cr...@marketeaminc.com
Hi

I dont know if you have seen this tutorial using XMPie Campus:


Start from 3 minutes 30 in and then watch what they do, Couch is right saying that you need to use an SQL data source in order to achieve this but it is very straightforward to create one:
  1. Open up your microsoft SQL server and login
  2. right click on Databases > New database...
  3. Once you have created a new database then you can right click on the new database select Tasks > Import Data
  4. Use the wizard to import your flat delimited file
  5. Once you have imported your data you have now got an SQL datasource that you can then link into the uStore data sources setup settings as per sylvains suggestion above
  6. The data source will now be selectable within your customization options for your dependent dropdown list.
I have got this working on a few stores I have setup and it works very well.

Let me know how you get on.

Regards

Simon Knott

Tom Komin

unread,
Aug 31, 2015, 3:09:24 AM8/31/15
to XMPie Interest Group, sco...@gmail.com, cr...@marketeaminc.com
Is there a way for the drop down menu to automatically select the value if only 1 value exists. I am using this for a product but after I click on the first selection. The remaining boxes (4 in total) only have 1 possible value for each one. Right now, the user has to select each item individually even though only 1 value is available.

For better understanding, I am having a user select an address. Based on that address, other selections appear for "address2, city, state, zip" but they only have 1 possible value that matches the address1 selection. If there is a better way of doing this, please let me know. Ideally, I would like for them to chose a location by name and then have all of the address fields populate by themselves. Or better yet, not show the info on the webpage but use the resulting text in creating the dynamic item. 

Thanks for your help. I am new to XMpie and I am not sure the exact way to get some things to work in Ustore.

couch

unread,
Aug 31, 2015, 3:47:38 AM8/31/15
to XMPie Interest Group
In the value list, there is a checkbox called "default".

Sylvain

unread,
Sep 3, 2015, 9:46:24 AM9/3/15
to XMPie Interest Group, sco...@gmail.com, cr...@marketeaminc.com
You can do dependencies using the connected DBs and/or flat files, you could even mix both methods if you wanted to. I do it both ways but, none of it is an "out of box feature", and none of it is done through the SDK. It's all Javascript.
Once you find a way to make your data available to the page, you can do just about anything with it. Keep it simple!

MarkeTeam Inc Creative

unread,
Sep 4, 2015, 2:17:10 PM9/4/15
to XMPie Interest Group, sco...@gmail.com, cr...@marketeaminc.com
Thanks Sylvain. I have been attempting off and on to create the dropdown but I have run into some connection issue with our server but I have logged a case for it.

I do have one question regarding the dropdown. On the attached image, the content in the red box will not be variable for the client to edit. They will choose a wine from the dropdown and whatever item they choose will populate the boxed content.

Any suggestion as to how I would write a rule(s) to make this function based on my datasource?  *See attachment.
MenuShell.jpg
datasource.png

Sylvain

unread,
Sep 4, 2015, 4:10:48 PM9/4/15
to XMPie Interest Group, sco...@gmail.com, cr...@marketeaminc.com
In order to pull the wine info, you need something to Key on. In your case, that'd be "Lookup" in your data. I picked Lookup because it appears to be a unique value for each record.
If the user is picking the wine from a dropdown, and that drop down is generated by uStore using your connected DB, you'd want "Lookup", or it's equivalent to populate the "[VALUE]" of the dropdown. Throw whatever in "[TEXT]". "[TEXT]" is what the user sees and selects. "[VALUE]" is what makes it to uPlan.

DropDown SQL query: Select [LOOKUP] as [VALUE], [WATHEVER] as [TEXT], [ISDEFAULT] = 0 from YOUR_TABLE_NAME;
You can then use and re-use the CampaignDial that holds that "Lookup" value to pull the proper information out of your userviews in order to populate the indesign document.

Lets pretend the user picks a value from a "Variable Campaign Dial"(A uPlan variable marked as a Campaign Dial) called PickedWine1. The uPlan representation of that variable is "@{PickedWine1}".

UserView SQL Query: Select * from YOUR_TABLE_NAME where Lookup = @{PickedWine1}
You userview is then populated with the information specific to the wine picked by the user.

MarkeTeam Inc Creative

unread,
Sep 8, 2015, 12:54:49 PM9/8/15
to XMPie Interest Group, sco...@gmail.com, cr...@marketeaminc.com
Thanks Sylvain. I'll give it a try.

Goutham Edubilli

unread,
Sep 15, 2015, 1:35:52 AM9/15/15
to XMPie Interest Group, sco...@gmail.com, cr...@marketeaminc.com
Hi Sylvain,

Can you please explain how to write a query in USTORE. I have gone through different approaches but didn't able to figure out that how to pass value.My code for text box as goes below.

select Price1 as [Value], 1 AS [ISDEFAULT]  from PriceTier  WHERE [Tiers]=  ????????

How to pass user selected dial value. For example i tried to pass as @VariableDial, '
@VariableDial' where
VariableDial is the user dial value. Based on the value i have to populate in the next text box

Thanks,
Goutham

Goutham Edubilli

unread,
Sep 15, 2015, 1:35:52 AM9/15/15
to XMPie Interest Group, sco...@gmail.com, cr...@marketeaminc.com
Hi Sylvain,

Can you please explain how to write a query in USTORE. I have gone through different approaches but didn't able to figure out that how to pass value.My code for text box as goes below.

select Price1 as [Value], 1 AS [ISDEFAULT]  from PriceTier  WHERE [Tiers]=  ????????

How to pass user selected dial value. For example i tried to pass as @VariableDial, '
@VariableDial' where
VariableDial is the user dial value. Based on the value i have to populate in the next text box

Thanks,
Goutham


On Saturday, September 5, 2015 at 1:40:48 AM UTC+5:30, Sylvain wrote:

Goutham Edubilli

unread,
Sep 15, 2015, 1:35:52 AM9/15/15
to XMPie Interest Group, sco...@gmail.com, cr...@marketeaminc.com
Hi Sylvain,

Can you please explain how to write a query in USTORE. I have gone through different approaches but didn't able to figure out that how to pass value.My code for text box as goes below.

select Price1 as [Value], 1 AS [ISDEFAULT]  from PriceTier  WHERE [Tiers]=  ????????

How to pass user selected dial value. For example i tried to pass as @VariableDial, '
@VariableDial' where
VariableDial is the user dial value. Based on the value i have to populate in the next text box

Thanks,
Goutham

On Saturday, September 5, 2015 at 1:40:48 AM UTC+5:30, Sylvain wrote:

Sylvain

unread,
Sep 21, 2015, 4:23:05 PM9/21/15
to XMPie Interest Group, sco...@gmail.com, cr...@marketeaminc.com
Sorry I haven't been here in a while.
I'm not yet on the latest uStore release so I don't have "out-of-the-box" dependent anything other than the Product Properties. So I'm not sure if what you're trying to do is actually do-able in uStore without coding a plugin.
In my uStore 7.x: As far as I know, uStore makes all the query calls on page load. You're trying to make it do a call upon user selection, which happens after the page has loaded.

MarkeTeam Inc Creative

unread,
Sep 29, 2015, 1:42:53 PM9/29/15
to XMPie Interest Group
I've finally gotten around to creating my Dependent Dropdown but not of the values (content/images) are changing to reflect what is on my data source. I feel like I am missing something in the Lookup Dial (See Lookup01 Dial Details.png). Whatever drop-down option I select, the same products show for all 3 options (See Menushell.png and Store options.png).

Also, Is there a way to remove an option from the dropdown if it has already been chosen from the previous 2?
MenuShell.png
Lookup01 Dial Details.png
Datasource.png

Sylvain

unread,
Oct 2, 2015, 9:58:33 AM10/2/15
to XMPie Interest Group
In your plan... 1 Database view per Ador/Wine, or basically, one user view per possible user selection. Each view uses its own uStore variable(campaign dial)

View 1 Query: Select Field1, Field2, Field3, from WhateverTable where WhateverField = @{Lookup01}
Ador1 Content: [View1].[Field2]

View 2 query: Select Field1, Field2, Field3, from WhateverTable where WhateverField = @{Lookup02}
Ador2 Content: [View2].[Field2]

MarkeTeam Inc Creative

unread,
Oct 20, 2015, 4:53:59 PM10/20/15
to XMPie Interest Group, sco...@gmail.com, cr...@marketeaminc.com


Can't get the dropdown to function properly. Based on the attached image, are my settings correct?




On Friday, September 4, 2015 at 1:10:48 PM UTC-7, Sylvain wrote:

Sylvain

unread,
Oct 20, 2015, 5:08:17 PM10/20/15
to XMPie Interest Group, sco...@gmail.com, cr...@marketeaminc.com
For some reason the picture you attached isn't coming through on my desktop, nor my phone.

MarkeTeam Inc Creative

unread,
Oct 20, 2015, 5:11:54 PM10/20/15
to XMPie Interest Group, sco...@gmail.com, cr...@marketeaminc.com
Are you able to view this one?




On Tuesday, October 20, 2015 at 1:53:59 PM UTC-7, MarkeTeam Inc Creative wrote:


Can't get the dropdown to function properly. Based on the attached image, are my settings correct?
...
Screen Shot 2015-10-20 at 12.31.06 PM.png

Sylvain

unread,
Oct 20, 2015, 5:32:51 PM10/20/15
to XMPie Interest Group, sco...@gmail.com, cr...@marketeaminc.com
I do see that one.
I have always used the "Custom" queries in uStore. I tested your settings and the dropdown "works" on my interface.
What is not working on your end? The dropdown it-self or the actions that should be executed based on the user selection?

MarkeTeam Inc Creative

unread,
Oct 20, 2015, 5:49:36 PM10/20/15
to XMPie Interest Group, sco...@gmail.com, cr...@marketeaminc.com
I can't seem to get the dropdown to pull any information from the datasource. The only thing that is showing is the list of wines in the dropdown.

You replied to a post from me on Sept. 4 with this information:

 (DropDown SQL query: Select [LOOKUP] as [VALUE], [WATHEVER] as [TEXT], [ISDEFAULT] = 0 from YOUR_TABLE_NAME;
You can then use and re-use the CampaignDial that holds that "Lookup" value to pull the proper information out of your userviews in order to populate the indesign document.).

Is this what I would place in the Custom Query?

Sylvain

unread,
Oct 20, 2015, 10:41:31 PM10/20/15
to XMPie Interest Group, sco...@gmail.com, cr...@marketeaminc.com
The only thing that is showing is the list of wines in the dropdown.
What else should there be in the drop down? The settings in your screenshot look ok and you're getting a list of wine.


Is this what I would place in the Custom Query?
You can't use my query as is.

Select [LOOKUP] as [VALUE], [WHATEVER] as [TEXT], [ISDEFAULT] = 0 from YOUR_TABLE_NAME;

[LOOKUP]-> the Lookup column of your data
[VALUE] -> the value attribute of the of the dropdpown option.
[LOOKUP] as [VALUE] -> make [LOOKUP] the [VALUE] that gets sent to uPlan. the user does not see this value.

[WHATEVER] -> you need to replace WHATEVER with a data column name
[TEXT] - > the text that represents the value. the text the users sees in the dropdown. this is not what gets sent to uplan.
[WHATEVER] as [TEXT] -> make [WHATEVER] the [TEXT] users will see in the drop down.

[ISDEFAULT] = 0 ; this means index O of the dropdown is default. your query could include logic to determine a different index, therefore a different default selection.

According to your screenshot LOOKUP would remain, WHATEVER would become LOOKUP and leave default the way it is.
Select [LOOKUP] as [VALUE], [LOOKUP] as [TEXT], [ISDEFAULT] = 0 from DBWines;

MarkeTeam Inc Creative

unread,
Oct 21, 2015, 4:38:47 PM10/21/15
to XMPie Interest Group, sco...@gmail.com, cr...@marketeaminc.com
Is there anything I should be doing in uPlan for this to function properly? I get the dropdown listings but the content (bottle image, vintage, wine type, red text and the description paragraph) does not change based on my selection.

I placed this in the custom query section but I feel like there is something else I should be doing.

Select [LOOKUP] as [VALUE], [LOOKUP] as [TEXT], [ISDEFAULT] = 0 from DBWines;

This is how it should look.

MarkeTeam Inc Creative

unread,
Oct 27, 2015, 12:34:35 PM10/27/15
to XMPie Interest Group
Is there someone that can assist me in populating a SellSheet with information from a datasource? I have created the dependent drop down that shows the list of items in column 1 of the datasource. What is NOT happening is that the information from the other columns (Vintage, Wine, Designation 1, Designation 2, Appellation 1, Appellation 2, Description and Bottle Image) are not showing on the SellSheet when I choose an item from the drop down. Attached is snippet of the datasource as well as what the sellsheet would look like if an item was selected from the dropdown.

In addition to the above information, I need to remove an item from a section if it is chosen in a previous section. IE: you choose Pinot Noir 667 in section 1 so it should not be an option in sections 2 and 3. Any assistance would be greatly appreciated.



Thank you
sellsheet-10.27.15.png
datasource10.27.15.png

simon knott

unread,
Oct 27, 2015, 1:30:03 PM10/27/15
to xmpie...@googlegroups.com
Hi

If you would like to achieve this then the way to go about it is to use User Views in your plan along with a secondary data source.

What you need to do first is in your plan goto > Data Sources > right click > New Data Source > Import using wizard

This will allow you to import your list of wines data source then you will need to goto > User Views > Right click > New User View

Then on your new User View you will need to add Field placeholders that will match the ones from your additional data source.

Then once you have done this you will need to create a variable that will be what will be connected to your dropdown list in your product and then in the user view you will need to write a query that would look something like this:

Select *
From @[MyDataSource]
Where @[MyDataSource].[Lookup] = @{MyVariable}

Then in the ADORs you place the User View placeholders in.

I have attached a plan and simple data source to explain better but it should get you started in the right direction.



--
You received this message because you are subscribed to a topic in the Google Groups "XMPie Interest Group" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/xmpie-users/HHLcgdJQXvU/unsubscribe.
To unsubscribe from this group and all its topics, send an email to xmpie-users...@googlegroups.com.
To post to this group, send email to xmpie...@googlegroups.com.
Visit this group at http://groups.google.com/group/xmpie-users.
For more options, visit https://groups.google.com/d/optout.

MyDataSource.txt
UserView.plan

MarkeTeam Inc Creative

unread,
Oct 27, 2015, 1:40:40 PM10/27/15
to XMPie Interest Group
Thanks Simon. I'll give it a shot. For some reason I am unable to open the UserView.plan file in uPlan.

simon knott

unread,
Oct 27, 2015, 1:43:01 PM10/27/15
to xmpie...@googlegroups.com
No problem good luck give us a shout if you get stuck with anything, It could be that I am using XMPie uPlan 7.5.1?

I should remind you that in order to use the secondary data source it needs to be defined in your data sources setup in ustore but im sure if you have allready got that working in the depedant dropdown list then you will have this setup already.

MarkeTeam Inc Creative

unread,
Oct 28, 2015, 11:07:51 AM10/28/15
to XMPie Interest Group
 My apologies Simon, but where you mentioned adding Field placeholders, could you give me an example of what the code would look like? And as far as the step after creating the placeholder, if I understand correctly, I would just be creating 1 variable for the lookup right?

Sorry for all of the questions. The training we had was probably 90% inDesign and very little on uPlan.


On Tuesday, October 27, 2015 at 10:30:03 AM UTC-7, Simon Knott wrote:

Simon Knott

unread,
Oct 28, 2015, 11:18:35 AM10/28/15
to XMPie Interest Group
No problem

Was you able to open the plan in the end?

What you need to do is on the User View goto > MyUserView (that you just created) > Right click > New Field

This will need to be done for each field in the additional data source:

MarkeTeam Inc Creative

unread,
Oct 28, 2015, 11:54:52 AM10/28/15
to XMPie Interest Group
Thanks for the diagram.

No. I was not able to open the plan file. Is uPlan 7.5.1 available yet? I see uDirect on xmpie.com but not uPlan.

simon knott

unread,
Oct 28, 2015, 12:01:19 PM10/28/15
to xmpie...@googlegroups.com
Yes I am running 7.5.1 version myself but I have had the server updated as well so I would speak to your xmpie support to arrange an upgrade.
Reply all
Reply to author
Forward
0 new messages