Red Gate forums :: View topic - Matching MS SQL type "Numeric" in a customized generator.
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

Matching MS SQL type "Numeric" in a customized generator.

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



Joined: 18 Oct 2011
Posts: 1

PostPosted: Tue Oct 18, 2011 2:45 pm    Post subject: Matching MS SQL type "Numeric" in a customized generator. Reply with quote

Hi I'm trying to customize a Int32generator to fill data into a field of type numeric(38,0).

What type should I use in the configuration to be able to match the field

I've tried with something like:
<type type="Numeric" />
<type type="numeric" />
<type type="Numeric(38,0)" />
...

But none of those works for me.

Any suggestions?

Btw: I don't have control of the database schema so changing the field type is not an option.
Back to top
View user's profile Send private message
james.billings



Joined: 16 Jun 2010
Posts: 1112
Location: My desk.

PostPosted: Wed Oct 19, 2011 4:21 pm    Post subject: Reply with quote

Thanks for your post. The below seems to work for me, although you'll need to copy your xml file into the "Config" folder for Data Generator to pick it up I think (at least, I did!)

<?xml version="1.0" encoding="iso-8859-1"?>
<generators>
<generator
type="RedGate.SQLDataGenerator.Generators.Number.Int32Generator"
name="MyNumericGenerator"
description="Testing!"
category="Example">

<property name="Increment">1</property>
<property name="MinValue">1</property>
<property name="MaxValue">1000</property>

<type sqlType="Integer64"/>
<type sqlType="Integer32"/>
<type sqlType="Integer16"/>
<type sqlType="Byte"/>
<type sqlType="Numeric"/>
</generator>
</generators>
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