SubSonic Oracle 和属性案例 [英] SubSonic Oracle and properties case

查看:23
本文介绍了SubSonic Oracle 和属性案例的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我不知道这个问题的答案.

I don´t know the answer for this question.

对于 MSSQLSERVER 和 MYSQL,下一个配置运行良好,但对于 Oracle 则不行.

With MSSQLSERVER and MYSQL the next configuration runs very well but with Oracle don´t.

用Oracle出现这样

With Oracle appear like this

货物 c = new Cargo();c.Idcargo = 1;

Cargo c = new Cargo(); c.Idcargo = 1;

使用 MSSQL 和 MYSQL

With MSSQL AND MYSQL

c.IdCargo = 1;

c.IdCargo = 1;

如何配置与 Oracle 的连接显示IdCargo"而不是Idcargo".??

How to configure the connection with Oracle to appear "IdCargo" and not "Idcargo". ??

配置:

    <providers>
        <clear/>
        <add name="oracle" type="SubSonic.oracleDataProvider, SubSonic"
   connectionStringName="oracle"
   fixDatabaseObjectCasing="true"
   regexDictionaryReplace="Empresaendereco,EmpresaEndereco;Empresacontato,EmpresaContato;Franqueadoendereco,FranqueadoEndereco;Franqueadocontato,FranqueadoContato;Funcionarioacesso,FuncionarioAcesso;Funcionarioendereco,FuncionarioEndereco;Funcionariocontato,FuncionarioContato;Clienteendereco,ClienteEndereco;Clientecontato,ClienteContato;Clientehistorico,ClienteHistorico;Agendastatus,AgendaStatus;Historicostatus,HistoricoStatus"
   generateRelatedTablesAsProperties="true"
   fixPluralClassNames="false"
   generatedNamespace="ModeloDados"
   regexIgnoreCase="false"
   removeUnderscores="false"
   setPropertyDefaultsFromDatabase="true"
   generateNullableProperties="true"
   useExtendedProperties="true" useUtc="true"/>
    </providers>

推荐答案

Valmir,您的 Cargo Table 的定义是什么样的?如果您的定义看起来像这样,我敢打赌您的错误来自 Oracle 而不是 SubSonic

Valmir, What does the definition of your Cargo Table look like? I am betting that your error is coming from Oracle and not SubSonic if your definition looks something like this

Create Table Cargo(
ldCargo Decimal(12,0) )

您的亚音速资产不会被视为 ldCargo.这是因为 Oracle 将所有列名和表名存储为大写.如果您想让它在 SubSonic 中以驼峰形式出现,则需要将 ldCargo 更改为 ld_cargo(SubSonic 将为您删除_")

Than your property in subsonic will not come across as ldCargo. This is due to the fact that Oracle stores all of the column names and table names as upper case. You would need to change ldCargo to ld_cargo if you would like to have it come across in SubSonic as camel case (SubSonic will remove the "_" for you)

这篇关于SubSonic Oracle 和属性案例的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆