Red Gate forums :: View topic - auto selected generators
Return to www.red-gate.com RSS Feed Available

Search  | Usergroups |  Profile |  Messages |  Log in  Register 
Go to product documentation
SQL Data Generator 1
SQL Data Generator 1 forum

auto selected generators

Search in SQL Data Generator 1 forum
Post new topic   Reply to topic
Jump to:  
Author Message
rjschave



Joined: 15 Apr 2008
Posts: 7

PostPosted: Fri Apr 18, 2008 7:11 am    Post subject: auto selected generators Reply with quote

I have several integer fields in a table that contain the words Length or Width in the field name. the program correctly selects the SQL int data generator for the Length fields, but selects the Business ID generator for the width fields.

I'm not sure why the word 'width' in the field name triggers the Business ID generator instead of the SQL int generator. What criteria is used to determine when a business generator is used over a SQL datatype generator? Is this a settings that can be modified?
Back to top
View user's profile Send private message
benhall



Joined: 14 Dec 2007
Posts: 98

PostPosted: Fri Apr 18, 2008 10:54 am    Post subject: Reply with quote

Hello,

Thank you for your post. Within the config directory of the application we have defined all of the generators as XML and set various properties which are loaded when the application starts.

For Business IDs (Ids.xml), we have a setting saying what to match the generator to. For this generator, it is:

" <matches field="ID" score="5" /> "

As width contains ID within the field name, the generator is automatically matching to the field name.

You can modify this by removing the configuration, I'll investigate the matching more to see if it can be improved.

Thanks

Ben
Back to top
View user's profile Send private message
rjschave



Joined: 15 Apr 2008
Posts: 7

PostPosted: Fri Apr 18, 2008 6:50 pm    Post subject: Reply with quote

Interesting. Thanks for the tip. I suppose normally it wouldn't be a big deal, but this table has over 12 fields with the word 'width' in the name so changing the generator was getting monotonous.

It sounds like your matching if the field name contains a value. Consider adding options for begins with and ends with.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic 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