| Author |
Message |
aseniuk
Joined: 16 Jun 2009 Posts: 15
|
Posted: Mon Dec 07, 2009 7:17 pm Post subject: Column Data Referenced / Selected by Another Columns Data |
|
|
Hi All,
I was wondering how I would do something like this. Lets say we want to get the gender of the person or rather select the gender first then fill in an appropriate name based on the gender.
Other areas where this would also be handy would be postal code, filling in the postal code based on the country/stat and, Phone numbers.
If anyone has an idea on how to achieve this please give me a post.
Thanks _________________ Database Analyst
Alberta Justice and Solicitor General |
|
| Back to top |
|
 |
Linda Hawksworth
Joined: 25 Jun 2007 Posts: 192
|
Posted: Wed Dec 09, 2009 11:46 am Post subject: |
|
|
SQL Data Generator will not do what you want out of the box but please see the following article:
http://www.simple-talk.com/content/article.aspx?article=697
which explains how to use the IronRuby generator to manipulate data. Specifically, please see the example of using conditional logis in that article:
title = table.row("Title")
if(title == "Mr")
column.set "M"
elsif(title == "Miss" or title == “Ms”)
column.set "F"
else
column.set "?"
end
You can use the NamesFirstMale.xml and NamesFirstFemale.xml files in the above code to specify male or female names in a specific column base on gender.
Let me know if this is what you need. |
|
| Back to top |
|
 |
|
|
All times are GMT + 1 Hour
|
| Page 1 of 1 |
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
Powered by phpBB © 2001, 2005 phpBB Group